UTF Character encoding in MySQL

I’ve had on going issues with mySQL not defaulting to UTF8 and instead using Latin1 constantly. After searching around a bit on the mySQL forums, I seem to have found a series of settings that put a halt to the problem once and for all. Just add these settings to your my.cnf file:




This entry was posted in programming, stoopid. Bookmark the permalink.

1 Response to UTF Character encoding in MySQL

  1. Alex Kudlick says:

    For mysql 5.5 on ubuntu 12.0 this should be:
    character_set_server = utf8
    collation_server = utf8_general_ci


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s