List:Internals« Previous MessageNext Message »
From:Mike Futerko Date:December 7 2005 4:43pm
Subject:Re: UTF8 Ukrainian collation
View as plain text  
Hello Alexander,

> ALTER DATABASE changes only the default collation, which
> will be used in the further CREATE TABLE. It doesn't touch
> the existing tables.
> 
> You have to alter your tables, for example:
> 
> 
> ALTER TABLE t1
>   MODIFY col1 VARCHAR(100) CHARACTER SET utf8 COLLATE utf8_unicode_ci;
> 
> 
> Or you can just run "mysqldump", then fix the dump file changeing
> "utf8_general_ci" to "utf8_unicode_ci" and then fed it back using
> "mysql".

The mysqldump trick didn't work for me, I have dumped the DB, dropped it 
by (DROP DATABASE) then created (CREATE DATABASE ... COLLATE 
utf8_unicode_ci;) and then restored the DB from dump. But again the sort 
order was definitely wrong. So I just altered necessary tables as per 
your example - that helped. Looks like even CREATE DATABASE with the 
preferred collation is buggy :(


Many thanks for the help,
Mike.
Thread
UTF8 Ukrainian collationMike Futerko2 Dec
  • Re: UTF8 Ukrainian collationSanja Byelkin5 Dec
  • Re: UTF8 Ukrainian collationAlexander Barkov7 Dec
    • Re: UTF8 Ukrainian collationMike Futerko7 Dec
      • Re: UTF8 Ukrainian collationAlexander Barkov7 Dec
        • Re: UTF8 Ukrainian collationMike Futerko7 Dec
          • Re: UTF8 Ukrainian collationAlexander Barkov8 Dec