P
P
pdx2011-02-06 14:08:07
MySQL
pdx, 2011-02-06 14:08:07

Question about collations in MySQL?

We have a table with the following structure:
mysql_collations_question_table_structur
It contains the following data:
mysql_collations_question_table_data.png
We make an experimental query:

SELECT<br/>
LOWER(`md5_upper_bin`),<br/>
LOWER(`md5_upper_ge_ci`),<br/>
UPPER(`md5_lower_bin`),<br/>
UPPER(`md5_lower_ge_ci`) <br/>
FROM `qwew`

We get the result:
mysql_collations_question_experimental_q
Question: why is the _bin postfix for these fields ignored in this case? Based on the MySQL mana, we can say that _bin also affects the string case conversion functions, so the presence of _bin in the name of the comparison should neutralize the effect of the LOWER and UPPER functions. Which doesn't happen in practice.

Answer the question

In order to leave comments, you need to log in

2 answer(s)
A
Andrew, 2011-02-06
@Morfi

Maybe you should use
SET NAMES binary

G
gro, 2011-02-06
@gro

Based on the MySQL mana, you can say that _bin also affects the string case conversion functions, so the presence of _bin in the name of the comparison should neutralize the effect of the LOWER and UPPER functions.

Why is the exact opposite written on the link you specified?

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question