| Bug #15224 | SHOW INDEX from temporary table doesn't work | ||
|---|---|---|---|
| Submitted: | 24 Nov 2005 13:59 | Modified: | 21 Dec 2005 18:04 | 
| Reporter: | Gleb Paharenko | Email Updates: | |
| Status: | Closed | Impact on me: | |
| Category: | MySQL Server | Severity: | S3 (Non-critical) | 
| Version: | 5.0.16/5.0.17 BK | OS: | Linux (Linux) | 
| Assigned to: | Sergei Glukhov | CPU Architecture: | Any | 
   [24 Nov 2005 14:15]
   MySQL Verification Team        
  Thank you for the bug report.
Reading table information for completion of table and column names
You can turn off this feature to get a quicker startup with -A
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 2 to server version: 5.0.17-debug
Type 'help;' or '\h' for help. Type '\c' to clear the buffer.
mysql> create temporary table a(a int, index(a));
Query OK, 0 rows affected (0.00 sec)
mysql> show indexes from a\G
ERROR 1146 (42S02): Table 'test.a' doesn't exist
mysql> select * from a;
Empty set (0.00 sec)
mysql> 
miguel@hegel:~/dbs/4.1> bin/mysql -uroot test
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 1 to server version: 4.1.16-log
Type 'help;' or '\h' for help. Type '\c' to clear the buffer.
mysql> create temporary table a(a int, index(a));
Query OK, 0 rows affected (0.03 sec)
mysql> show indexes from a\G
*************************** 1. row ***************************
       Table: a
  Non_unique: 1
    Key_name: a
Seq_in_index: 1
 Column_name: a
   Collation: A
 Cardinality: NULL
    Sub_part: NULL
      Packed: NULL
        Null: YES
  Index_type: BTREE
     Comment: 
1 row in set (0.01 sec)
mysql>
 
   [29 Nov 2005 11:48]
   Bugs System        
  A patch for this bug has been committed. After review, it may be pushed to the relevant source trees for release in the next version. You can access the patch from: http://lists.mysql.com/internals/32821
   [19 Dec 2005 10:41]
   Bugs System        
  A patch for this bug has been committed. After review, it may be pushed to the relevant source trees for release in the next version. You can access the patch from: http://lists.mysql.com/commits/243
   [19 Dec 2005 10:47]
   Sergei Glukhov        
  Fixed in 5.0.18
   [21 Dec 2005 18:04]
   Jon Stephens        
  Thank you for your bug report. This issue has been committed to our
source repository of that product and will be incorporated into the
next release.
If necessary, you can access the source repository and build the latest
available version, including the bugfix, yourself. More information 
about accessing the source trees is available at
    http://www.mysql.com/doc/en/Installing_source_tree.html
Additional info:
Documented in 5.0.18 changelog. Closed.
 

Description: In 5.0.16 'show index' from temporary table doesn't work, while it is working in 4.1.15. ANALYZE table doesn't work as well, and so on... How to repeat: mysql> select version(); +------------------+ | version() | +------------------+ | 5.0.16-debug-log | +------------------+ 1 row in set (0.00 sec) mysql> create temporary table a(a int, index(a)); Query OK, 0 rows affected (0.00 sec) mysql> show indexes from a\G; ERROR 1146 (42S02): Table 'test.a' doesn't exist ERROR: No query specified mysql> select version(); +------------------+ | version() | +------------------+ | 4.1.15-debug-log | +------------------+ 1 row in set (0.04 sec) mysql> create temporary table a(a int, index(a)); Query OK, 0 rows affected (0.00 sec) mysql> show indexes from a\G; *************************** 1. row *************************** Table: a Non_unique: 1 Key_name: a Seq_in_index: 1 Column_name: a Collation: A Cardinality: NULL Sub_part: NULL Packed: NULL Null: YES Index_type: BTREE Comment: 1 row in set (0.00 sec) Suggested fix: fix this or document