COLLATE 'latin1_danish_ci'
mysql> CREATE TABLE TWOCOLL
-> (C1 CHAR(10) COLLATE 'latin1_general_ci' NOT NULL,
-> C2 VARCHAR(10) COLLATE 'latin1_danish_ci')
-> ;
Query OK, 0 rows affected (0.00 sec)
mysql> INSERT INTO TWOCOLL VALUES ('A', 'A')
-> ;
Query OK, 1 row affected (0.00 sec)
mysql> SELECT *
-> FROM TWOCOLL
-> WHERE C1 = C2
-> ;
ERROR 1267 (HY000): Illegal mix of collations (latin1_general_ci,IMPLICIT) and (latin1_danish_ci,IMPLICIT) for operation '='
mysql> SELECT *
-> FROM TWOCOLL
-> WHERE C1 COLLATE latin1_danish_ci = C2
-> ;
+----+------+
| C1 | C2 |
+----+------+
| A | A |
+----+------+
1 row in set (0.00 sec)
mysql> SELECT *
-> FROM TWOCOLL
-> WHERE C1 COLLATE utf8_general_ci = C2;
ERROR 1253 (42000): COLLATION 'utf8_general_ci' is not valid for CHARACTER SET 'latin1'
mysql>
mysql>
Related examples in the same category