You are hereBlogs / michael.fernando's blog / Changing the Character Set and Collate of your MySQL Database

Changing the Character Set and Collate of your MySQL Database


By michael.fernando - Posted on 22 November 2009

Before changing the Char Set of your Database, here's How to view the character set and collate of your database:

use YOUR_DATABASE_NAME;

show variables like "character_set_database";

show variables like "collation_database";

Now that you know your Database isnt UTF-8, you can try Changing the character set from Latin to UTF 8:

alter database YOUR_DATABASE_NAME charset=utf8 collate=utf8_bin;

Share this

Follow me on: