Home > Archive > PHP SQL > January 2005 > storing UNICODE in MySQL
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
| Author |
storing UNICODE in MySQL
|
|
|
| Does MySGL allow storing text data in Unicode?
My web-host allows to enter data into a MySQL table using an HTML form which
accepts Cyrillics, but in the tablle all the Cyrillics is stored as entities
like xxx;
Is this the problem of the SQL settings, ot is has to do with the encoding
of HTML page contasinin the form, which is not Unicode?
Or both?
| |
|
|
| J.O. Aho 2005-01-14, 8:56 am |
| aa wrote:
> Thanks
>
> However my problem is not getting the data out of MySQL.
> My problem is how to force MySQL to store the data as Unicode. I know that
> MySQL is designed to handle Unicode and on my local computer MySQL
> downloaded from Internet does store data as Unicode.
>
> So the problem is with my web host - either they somehow set MySQL to use
> ANSI or the data are converted into ANSI on their way from the webpage to
> MySQL because the HTML page on which I enter the data, is ANSI.
Make a php script that has UTF-8 character that is stored into MySQL, run it
once and then check the entry in the table and see if it's modified or if it's
stored as it should be. If modified, then it's the MySQL that isn't set to
handle utf-8 (maybe they only support KOI).
//Aho
|
|
|
|
|