This is a discussion on Character set problem when upgrading to mysql 5.0x,suggestion needed~ within the MySQL Database forums, part of the Database Forums category; Here's the scenario,it's a lil bit long: I use mysql 4.0.16 for my working DB, ...
|
|||||||
| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
|
|||
|
Here's the scenario,it's a lil bit long:
I use mysql 4.0.16 for my working DB, one day i found that sometimes when inserting a record into the db it reports primary key replication error. then I found the reason for this: my primary key column stores data which is in gb2312 charset and mysql was compiled with latin1 as the default charset. so there's occasion that when i insert a record with a supposed-to-be distinctive primary key,it reports the primary key does already exist due to the charset reason.So I mysqldump my data out and recompile mysql with charset of gb2312 and reimport the data. BTW,when i mysqldump the data i didnt specify any charset option with mysqldump. now here's the problem, I see the bug report saying that there a bug in 4.0.x when using binlog try to recover the DB regarding to multibyte characters and yes i did have that problem all the way...that's why i needed to upgrade my mysql to 5.0.x. Does any one have any suggestion how should I dump my data out of 4.0.16 and recover it back to mysql 5.0.x and still make the charset works? i'm a lil confused about the charset... any suggestion is highly appreciated! Looking forward to your answer :) |