| Bug #2701 | Function CHARSET() inconsistency | ||
|---|---|---|---|
| Submitted: | 11 Feb 2004 2:20 | Modified: | 11 Feb 2004 4:58 |
| Reporter: | Alexander Barkov | Email Updates: | |
| Status: | Closed | Impact on me: | |
| Category: | MySQL Server | Severity: | S3 (Non-critical) |
| Version: | 4.1.2-bk-current | OS: | |
| Assigned to: | Alexander Barkov | CPU Architecture: | Any |
[11 Feb 2004 4:58]
Alexander Barkov
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

Description: Function charset() in SELECT and CREATE TABLE ... SELECT brings different charsets. The correct value is UTF8. How to repeat: mysql> select charset(charset('a')); +-----------------------+ | charset(charset('a')) | +-----------------------+ | latin1 | +-----------------------+ 1 row in set (0.00 sec) mysql> create table t1 select charset(charset('a')); Query OK, 1 row affected (0.07 sec) Records: 1 Duplicates: 0 Warnings: 0 mysql> show create table t1; +-------+--------------------------------------------------------------------------------------------------------------------------------------+ | Table | Create Table | +-------+--------------------------------------------------------------------------------------------------------------------------------------+ | t1 | CREATE TABLE `t1` ( `charset(charset('a'))` char(14) character set utf8 NOT NULL default '' ) ENGINE=MyISAM DEFAULT CHARSET=latin1 | +-------+--------------------------------------------------------------------------------------------------------------------------------------+ 1 row in set (0.00 sec)