Bug #6727 MySQL on Windows doesn't distinguish between 'ö' and 'ü'
Submitted: 19 Nov 2004 21:06 Modified: 14 Jan 2005 11:21
Reporter: Hartmut Holzgraefe Email Updates:
Status: Not a Bug Impact on me:
None 
Category:MySQL Server Severity:S3 (Non-critical)
Version:4.1.7 OS:Microsoft Windows (Windows XP)
Assigned to: Alexander Barkov CPU Architecture:Any

[19 Nov 2004 21:06] Hartmut Holzgraefe
Description:
This only happens on Windows, not Liunx,
it might even be an issue of german versions 
of Windows only (in the 7bit days german Umlauts
were mapped to [ ] etc.

How to repeat:
SELECT 'ö' = ']'

Expected result: 0

Actual result: 1
[19 Nov 2004 22:01] MySQL Verification Team
Yeah this maybe only a Germany version Windows:

c:\mysql\bin>mysql -uroot
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 1 to server version: 4.1.7-nt-log

Type 'help;' or '\h' for help. Type '\c' to clear the buffer.

mysql> SELECT 'ö' = ']'
    -> ;
+-----------+
| 'ö' = ']' |
+-----------+
|         0 |
+-----------+
1 row in set (0.09 sec)
[27 Dec 2004 8:40] Alexander Barkov
What do you have in

SHOW VARIABLES LIKE 'collation%';
[11 Jan 2005 13:46] Alexander Barkov
Also, 
SELECT HEX('ö'), HEX('ü');

would be helpful. Thanks!
[11 Jan 2005 13:48] Alexander Barkov
Can you also please clarify?

Subject lines says:
MySQL on Windows doesn't distinguish between 'ö' and 'ü'
While the test compares 'ö' to ']'.
[14 Jan 2005 11:20] Alexander Barkov
I guess the customer is using latin1_swedish_ci, which
really defines 'ö' = ']' for old swedish7 character set 
compatibility purposes.

If the customer doesn't like this behaviour, then
the best solution is to change the collation to
for example latin1_german1_ci:

mysql> select 'ж'=']' collate latin1_swedish_ci;
+-----------------------------------+
| 'ж'=']' collate latin1_swedish_ci |
+-----------------------------------+
|                                 1 |
+-----------------------------------+
1 row in set (0.00 sec)

mysql> select 'ж'=']' collate latin1_german1_ci;
+-----------------------------------+
| 'ж'=']' collate latin1_german1_ci |
+-----------------------------------+
|                                 0 |
+-----------------------------------+
1 row in set (0.00 sec)
[14 Jan 2005 11:21] Alexander Barkov
Thank you for taking the time to write to us, but this is not
a bug. Please double-check the documentation available at
http://www.mysql.com/documentation/ and the instructions on
how to report a bug at http://bugs.mysql.com/how-to-report.php