April 2010
2 posts
Character Sets and MySQL command line client
FYI… if connecting to a MySQL database using the MySQL command line client (tool) where the database collation / character-set is set to utf8_general_ci / UTF-8, you need to issue a SET NAMES 'utf8';   command prior to running any queries so that any special characters show up correctly. Refer to the MySQL Reference Manual, section 9.1.4. Connection Character Sets and Collations and...
Apr 22nd
Character Sets and PHP Follow Up
Following up to my Feb 23, 2010 post on  difficulties with charaster sets I’ve yet run into another example of how this can mess you up. In PHP, I was using curl to fetch a page from a remote web server and then extract some data using regex and then inserting it into a MySQL database. The issue that I encountered was that my database was in was in UTF-8 but the text being retrieved from...
Apr 22nd