Description:
mysql 5.x client always shows latin1_swedish_ci as characterset although compiled with explicit character set and collation
i'm not sure if this is ab bug at all...
compilation:
CFLAGS="-O2 -mcpu=pentiumpro" CXX=gcc CXXFLAGS="-O2 -mcpu=pentiumpro -felide-constructors" ./configure --prefix /var/mysql5 --with-tcp-port=3307 --with-unix-socket-path=/var/run/mysql5.sock --with-collation=latin1_general_cs --with-charset=latin1 --without-debug --with-extra-charsets=complex --enable-thread-safe-client --enable-local-infile --enable-assembler --disable-shared --with-client-ldflags=-all-static --with-mysqld-ldflags=-all-static
startup:
/var/mysql5/bin/mysqld_safe --user=mysql --basedir=/var/mysql5 --character-set-server=latin1 --collation-server=latin1_general_cs --old-passwords --pid-file=/var/run/mysql5.pid --port=3307 --socket=/var/run/mysql5.sock --tmpdir=/tmp
client (called without any options):
mysql> status
--------------
mysql5 Ver 14.6 Distrib 5.0.2-alpha-nightly-20041103, for pc-linux (i686)
Connection id: 2
Current database:
Current user: root@localhost
SSL: Not in use
Current pager: /usr/bin/less
Using outfile: ''
Using delimiter: ;
Server version: 5.0.2-alpha-nightly-20041103
Protocol version: 10
Connection: Localhost via UNIX socket
Client characterset: latin1_swedish_ci
Server characterset: latin1_swedish_ci
UNIX socket: /var/run/mysql5.sock
Uptime: 11 min 17 sec
Threads: 1 Questions: 5 Slow queries: 0 Opens: 0 Flush tables: 1 Open tables: 0 Queries per second avg: 0.007
--------------
this only happens with the mysql5.x client (4.x shows latin1)
commands are executed correct:
mysql> create table x (a text);
mysql> show create table x;
+-------+--------------------------------------------------------------------------------------------------------------------------+
| Table | Create Table |
+-------+--------------------------------------------------------------------------------------------------------------------------+
| x | CREATE TABLE `x` (
`a` text collate latin1_general_cs
) ENGINE=MyISAM DEFAULT CHARSET=latin1 COLLATE=latin1_general_cs |
+-------+--------------------------------------------------------------------------------------------------------------------------+
1 row in set (0.00 sec)
How to repeat:
s.a.