Bug #5299 Remove SHOW COLUMN TYPES
Submitted: 30 Aug 2004 20:15 Modified: 12 Nov 2009 18:29
Reporter: Trudy Pelzer Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Server Severity:S3 (Non-critical)
Version:4.1.4-gamma (ndb),5.0.37 OS:Any
Assigned to: Sergei Glukhov CPU Architecture:Any

[30 Aug 2004 20:15] Trudy Pelzer
Description:
SHOW COLUMN TYPES is supposed to provided information about the 
data types supported for column definitions. Right now, it shows only 
two data types: TINYINT and TINYINT UNSIGNED: 
 
mysql> show column types; 
+------------------+------+-----------+-----------+------+-------+----------+----------------+----------+----------+------------+----------------+---------+----------------------+ 
| Type             | Size | Min_Value | Max_Value | Prec | Scale | Nullable | 
Auto_Increment | Unsigned | Zerofill | Searchable | Case_Sensitive | Default | Comment              
| 
+------------------+------+-----------+-----------+------+-------+----------+----------------+----------+----------+------------+----------------+---------+----------------------+ 
| tinyint          |    1 | -128      | 127       |    0 |     0 | YES      | YES            | NO       | 
YES      | YES        | NO             | NULL,0  | A very small integer | 
| tinyint unsigned |    1 | 0         | 255       |    0 |     0 | YES      | YES            | YES      | 
YES      | YES        | NO             | NULL,0  | A very small integer | 
+------------------+------+-----------+-----------+------+-------+----------+----------------+----------+----------+------------+----------------+---------+----------------------+ 
2 rows in set (0.00 sec) 
 

How to repeat:
show column types; 
 

Suggested fix:
Update so that all valid data types are shown.
[31 Aug 2004 5:30] MySQL Verification Team
Than you for the bug report. I was able to repeat.
[23 Sep 2006 21:23] Andris Kardos
Would be a very nice addition to the information schema tables!
[2 May 2007 0:56] Todd Farmer
What should be done with this?  The problem remains in 5.0.37:

mysql> show column types\G
*************************** 1. row ***************************
          Type: tinyint
          Size: 1
     Min_Value: -128
     Max_Value: 127
          Prec: 0
         Scale: 0
      Nullable: YES
Auto_Increment: YES
      Unsigned: NO
      Zerofill: YES
    Searchable: YES
Case_Sensitive: NO
       Default: NULL,0
       Comment: A very small integer
*************************** 2. row ***************************
          Type: tinyint unsigned
          Size: 1
     Min_Value: 0
     Max_Value: 255
          Prec: 0
         Scale: 0
      Nullable: YES
Auto_Increment: YES
      Unsigned: YES
      Zerofill: YES
    Searchable: YES
Case_Sensitive: NO
       Default: NULL,0
       Comment: A very small integer
2 rows in set (0.00 sec)

mysql>

There is no online documentation for this command, nor is there anything HELP:

mysql> help show column types;

Nothing found
Please try to run 'help contents' for a list of all accessible topics
[2 May 2007 20:23] Timothy Smith
The agreement seems to be to remove this statement.  It's never been documented nor complete.
[2 May 2007 21:03] Jim Winstead
if we're to have a proper implementation of SQLGetTypeInfo() in the ODBC driver, we need some way of getting real info about the server's types. (whether a SHOW statement or an INFORMATION_SCHEMA table.)

see http://msdn.microsoft.com/library/default.asp?url=/library/en-us/odbc/htm/odbcsqlgettypein...
[28 Mar 2008 10:01] 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/44565

ChangeSet@1.2602, 2008-03-28 13:52:18+04:00, gluh@mysql.com +8 -0
  Bug#5299 Remove SHOW COLUMN TYPES
  Removed 'SHOW COLUMN TYPES' command
[19 Apr 2008 13:53] 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/45652

ChangeSet@1.2608, 2008-04-19 18:50:22+05:00, gluh@mysql.com +1 -0
  Bug#5299 Remove SHOW COLUMN TYPES
  added 'deprecated' warning for SHOW COLUMN TYPES command,
  this command will be removed in 6.0 version
[19 Apr 2008 14:54] 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/45655

ChangeSet@1.2620, 2008-04-19 19:52:10+05:00, gluh@mysql.com +10 -0
  Bug#5299 Remove SHOW COLUMN TYPES
  Removed 'SHOW COLUMN TYPES' command
[19 Apr 2008 17:23] 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/45661

ChangeSet@1.2609, 2008-04-19 22:21:51+05:00, gluh@mysql.com +1 -0
  Bug#5299 Remove SHOW COLUMN TYPES
  result fix
[28 May 2008 10:02] Bugs System
Pushed into 6.0.6-alpha
[29 May 2008 3:22] Paul DuBois
Noted in 6.0.6 changelog.

The undocumented, deprecated, and not useful SHOW COLUMN TYPES
statement has been removed.
[23 Oct 2009 7:19] 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/87887

2914 Sergey Glukhov	2009-10-23
      Bug#5299 Remove SHOW COLUMN TYPES, backport to Betony
     @ mysql-test/r/show_check.result
        Bug#5299 Remove SHOW COLUMN TYPES, backport to Betony
     @ mysql-test/r/signal_code.result
        Bug#5299 Remove SHOW COLUMN TYPES, backport to Betony
     @ mysql-test/r/sp-code.result
        Bug#5299 Remove SHOW COLUMN TYPES, backport to Betony
     @ mysql-test/r/sp.result
        Bug#5299 Remove SHOW COLUMN TYPES, backport to Betony
     @ mysql-test/t/show_check.test
        Bug#5299 Remove SHOW COLUMN TYPES, backport to Betony
     @ mysql-test/t/sp.test
        Bug#5299 Remove SHOW COLUMN TYPES, backport to Betony
     @ sql/mysqld.cc
        Bug#5299 Remove SHOW COLUMN TYPES, backport to Betony
     @ sql/sp_head.cc
        Bug#5299 Remove SHOW COLUMN TYPES, backport to Betony
     @ sql/sql_lex.h
        Bug#5299 Remove SHOW COLUMN TYPES, backport to Betony
     @ sql/sql_parse.cc
        Bug#5299 Remove SHOW COLUMN TYPES, backport to Betony
     @ sql/sql_prepare.cc
        Bug#5299 Remove SHOW COLUMN TYPES, backport to Betony
     @ sql/sql_show.cc
        Bug#5299 Remove SHOW COLUMN TYPES, backport to Betony
     @ sql/sql_yacc.yy
        Bug#5299 Remove SHOW COLUMN TYPES, backport to Betony
[31 Oct 2009 8:16] Bugs System
Pushed into 6.0.14-alpha (revid:alik@sun.com-20091031081410-qkxmjsdzjmj840aq) (version source revid:lars-erik.bjork@sun.com-20091023144402-05x9kn8fz878z011) (merge vers: 6.0.14-alpha) (pib:13)
[31 Oct 2009 17:21] Paul DuBois
Already fixed in 6.0.6.

Setting report to NDI pending push to 5.5.x
[12 Nov 2009 8:21] Bugs System
Pushed into 5.5.0-beta (revid:alik@sun.com-20091110093229-0bh5hix780cyeicl) (version source revid:mikael@mysql.com-20091102100915-a2nbfxaqprpgptfw) (merge vers: 5.5.0-beta) (pib:13)
[12 Nov 2009 18:29] Paul DuBois
Noted in 5.5.0 changelog.