How can I set connection charset to utf8
in apache mod_dbd
with mysql driver? I could not find any corresponding parameter in DBDParams
, something like this:
DBDParams host=localhost,dbname=my_db,user=my_user,pass=my_pass,reconnect=0,charset=utf8
which of course there is no such charset
parameter in reality.
utf-8 is not part of the connection, it's how the database is managing its charset. You need to convert your database over if you want things to be transmitted and handled in utf-8. Found this on StackOverflow:
https://stackoverflow.com/questions/6115612/how-to-convert-an-entire-mysql-database-characterset-and-collation-to-utf-8
which should lead you down the right path.