views:

62

answers:

1

hello, I have noticed a problem with "non-english" (polish) characters using MySQL.

query "select 'abcde'='ąbćdę'" returns "1" and the strings are not equals ...

could you help me ? :) thx!!!

+3  A: 

For utf8_general_ci they are equal (with the exception of ł, which is not considered a bug by MySQL). Use utf8_polish_ci to treat accented and unaccented characters as different.

select 'abcde'='ąbćdę' COLLATE utf8_polish_ci
>> 0

Demo of 'not a bug'

select 'abcde'='ąbćdę' COLLATE utf8_general_ci
>> 1

select 'abcdel'='ąbćdęł' COLLATE utf8_general_ci
>> 0

See the bug report here: http://bugs.mysql.com/bug.php?id=9604

Mchl