summaryrefslogtreecommitdiff
path: root/sql/sql_show.cc
diff options
context:
space:
mode:
authorunknown <gluh@eagle.intranet.mysql.r18.ru>2005-12-19 14:46:54 +0400
committerunknown <gluh@eagle.intranet.mysql.r18.ru>2005-12-19 14:46:54 +0400
commit959ce2410704ad6cfa7a477e636cd75e257d9cfd (patch)
tree76e187f35a35611c5a23bae59d5d98ab6c9544af /sql/sql_show.cc
parent1d3c2fa4e7ea4d29f50a96c48624d152a25bbf8e (diff)
downloadmariadb-git-959ce2410704ad6cfa7a477e636cd75e257d9cfd.tar.gz
Bug#12770 DESC cannot display the info. about temporary table
Bug#14387 SHOW COLUMNS doesn't work on temporary tables. Bug#15224 SHOW INDEX from temporary table doesn't work. Restore thd->temporary_tables to be able to process temporary tables(only for 'show index' & 'show columns'). This should be changed when processing of temporary tables for I_S tables will be done. mysql-test/r/information_schema.result: Bug#12770 DESC cannot display the info. about temporary table Bug#14387 SHOW COLUMNS doesn't work on temporary tables. Bug#15224 SHOW INDEX from temporary table doesn't work. test case mysql-test/t/information_schema.test: Bug#12770 DESC cannot display the info. about temporary table Bug#14387 SHOW COLUMNS doesn't work on temporary tables. Bug#15224 SHOW INDEX from temporary table doesn't work. test case
Diffstat (limited to 'sql/sql_show.cc')
-rw-r--r--sql/sql_show.cc8
1 files changed, 8 insertions, 0 deletions
diff --git a/sql/sql_show.cc b/sql/sql_show.cc
index 82870d46e6c..dc6c141bef7 100644
--- a/sql/sql_show.cc
+++ b/sql/sql_show.cc
@@ -2069,6 +2069,13 @@ int get_all_tables(THD *thd, TABLE_LIST *tables, COND *cond)
bool res;
lex->all_selects_list= lsel;
+ /*
+ Restore thd->temporary_tables to be able to process
+ temporary tables(only for 'show index' & 'show columns').
+ This should be changed when processing of temporary tables for
+ I_S tables will be done.
+ */
+ thd->temporary_tables= open_tables_state_backup.temporary_tables;
res= open_normal_and_derived_tables(thd, show_table_list,
MYSQL_LOCK_IGNORE_FLUSH);
/*
@@ -2088,6 +2095,7 @@ int get_all_tables(THD *thd, TABLE_LIST *tables, COND *cond)
show_table_list->view_db.str :
show_table_list->db),
show_table_list->alias));
+ thd->temporary_tables= 0;
close_thread_tables(thd);
show_table_list->table= 0;
goto err;