Bug #8235 Connection collation change & table create with default result in crash
Submitted: 1 Feb 2005 10:42 Modified: 7 Mar 2005 0:37
Reporter: Daan Broekhof Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Server Severity:S2 (Serious)
Version:4.1.9/BK 4.1/BK 5.0 OS:Linux (Slackware 10.0)
Assigned to: Alexander Barkov

[1 Feb 2005 10:42] Daan Broekhof
Description:
In stock mysql 4.1.9, the following 2 queries executed on one connection result in a "#2013 - Lost connection to MySQL server during query" error. 

SET collation_connection='ucs2_swedish_ci';
CREATE TABLE TestTable( Field1 int( 10 ) default '0' );

If the table type is MyISAM, the table is created normally, and can be dropped.
If the table type is InnoDB, the table cannot be dropped and shows as 'in use'.

When you use a default value without the quotes, no error occurs.
eg: CREATE TABLE TestTable( Field1 int( 10 ) default 0 );

Error occurs when you set the connection collation to anything other then the current server collation.

How to repeat:
SET collation_connection='ucs2_swedish_ci';
CREATE TABLE TestTable( Field1 int( 10 ) default '0' );

On stock 4.1.9

Suggested fix:
More collation checks?
[1 Feb 2005 13:02] Miguel Solorzano
Thank you for the bug report. I was able to repeat on current
BK source tree.
[1 Feb 2005 13:14] Miguel Solorzano
Also 5.0 tree is affected.
[12 Feb 2005 12:41] Alexander Barkov
Fixed in 4.1.10.

I haven't merged into 5.0.x though, because of conflicts
in someone's else changes.
[7 Mar 2005 0:37] Paul Dubois
Noted in 4.1.10, 5.0.3 changelogs.