Bug #7173 Add charset and collation to 'DESCRIBE table' output
| Submitted: | 10 Dec 2004 15:57 | Modified: | 15 Feb 2006 13:00 |
|---|---|---|---|
| Reporter: | Struchkov Vladimir | Email Updates: | |
| Status: | Verified | Impact on me: | |
| Category: | MySQL Server: Information schema | Severity: | S4 (Feature request) |
| Version: | >=4.1 | OS: | Any (All) |
| Assigned to: | CPU Architecture: | Any |
[10 Dec 2004 15:57]
Struchkov Vladimir
[15 Feb 2006 13:00]
Valeriy Kravchuk
Thank you for the reasonable feature request. It is more appropriate for SHOW CREATE TABLE, but separate different collations for columns may be also reported by DESC.
[3 Oct 2008 16:49]
Konstantin Osipov
Hello Vova, Starting from 5.0 you can use INFORMATION_SCHEMA.
[3 Oct 2008 23:15]
Paul DuBois
Workaround. Use SHOW COLUMNS rather than DESCRIBE. SHOW COLUMNS supports a FULL keyword such that SHOW FULL COLUMNS includes a Collation field for character columns. The Collation value gives you the collation explicitly and the character set by implication. Example:
mysql> SHOW FULL COLUMNS FROM t\G
*************************** 1. row ***************************
Field: i
Type: int(11)
Collation: NULL
Null: YES
Key:
Default: NULL
Extra:
Privileges: select,insert,update,references
Comment:
*************************** 2. row ***************************
Field: c
Type: char(10)
Collation: latin1_swedish_ci
Null: YES
Key:
Default: NULL
Extra:
Privileges: select,insert,update,references
Comment:
2 rows in set (0.00 sec)
Portions of this website are copyright © 2001, 2002 The PHP Group
Page generated in 0.072 sec. using MySQL 8.4.7-u6-cloud
Timestamp references displayed by the system are UTC.
Content reproduced on this site is the property of the
respective copyright holders.
It is not reviewed in advance
by Oracle and does not necessarily represent the opinion of
Oracle or any other party.