Re: Collation problem when used with "SET NAMES"
Changing collation_connection with SET NAMES will affect comparison of
literals.
For example:
mysql> set names utf8;
Query OK, 0 rows affected (0.00 sec)
mysql> select 'Mü' = 'My';
+--------------+
| 'Mü' = 'My' |
+--------------+
| 0 |
+--------------+
1 row in set (0.00 sec)
mysql> set names utf8 collate utf8_swedish_ci;
Query OK, 0 rows affected (0.00 sec)
mysql> select 'Mü' = 'My';
+--------------+
| 'Mü' = 'My' |
+--------------+
| 1 |
+--------------+
1 row in set (0.00 sec)
Your example seems to be selecting from a table.
Therefore the important thing is the column's collation.
Peter Gulutzan
MySQL AB
Subject
Views
Written By
Posted
2480
July 28, 2006 08:14AM
Re: Collation problem when used with "SET NAMES"
1694
July 28, 2006 08:53AM
1998
July 28, 2006 09:38AM
Sorry, you can't reply to this topic. It has been closed.
Content reproduced on this site is the property of the respective copyright holders.
It is not reviewed in advance by Oracle and does not necessarily represent the opinion
of Oracle or any other party.