Bug #19598 Accented characters not displayed correctly
Submitted: 7 May 2006 23:34 Modified: 9 May 2006 3:38
Reporter: Daniel Cournoyer Email Updates:
Status: Not a Bug Impact on me:
None 
Category:MySQL Server Severity:S2 (Serious)
Version:5.0.21 OS:Linux (Linux)
Assigned to: CPU Architecture:Any

[7 May 2006 23:34] Daniel Cournoyer
Description:
From MySQL 5.0.19 to 5.0.21, accented characters (ISO-8859-1) are not displayed correctly on any PHP page, even if my "character-set-server" and "default-character-set" are set to latin1 in my my.cnf file

How to repeat:
Install MySQL and try to output a PHP page with the character é, è, à, ç, etc.

Suggested fix:
Add the line:
init-connect='SET NAMES latin1'

under [mysqld] section.
[8 May 2006 14:50] Hartmut Holzgraefe
The only character set setting that is relevant here is the client character set
as any data sent to the client is converted to the client charset first, and this
is exactly one of the settings modified by SET NAMES

With the new ext/mysqli it might be possible to have default-character-set 
in the [client] section to solve this, but i haven't tested this yet ..
[9 May 2006 3:38] Daniel Cournoyer
Yes, it works with the "default-character-set" set in the [client] field (just tested). I think this should be added in the MySQL documentation since it cause me a BIG headache for a few days and I saw many mention about this on the net.