CREATE OR REPLACE TABLE t3 (
  a VARCHAR(32) CHARACTER SET utf8mb3 COLLATE uca1400_ai_ci
);

DELIMITER $$
FOR i IN 0..0xFFFF
DO
  INSERT INTO t3 VALUES (CHAR(i USING utf32));
END FOR;
$$
DELIMITER ;

SELECT t1.a, t2.a, (t1.a=t2.a), UCASE(t1.a), UCASE(t2.a), (UCASE(t1.a)=UCASE(t2.a)), HEX(t1.a), HEX(t2.a), HEX(UCASE(t1.a)), HEX(UCASE(t2.a)) FROM t3 t1, t3 t2 WHERE (t1.a=t2.a) <> (UCASE(t1.a)=UCASE(t2.a));
+------+------+-------------+-------------+-------------+---------------------------+-----------+-----------+------------------+------------------+
| a    | a    | (t1.a=t2.a) | UCASE(t1.a) | UCASE(t2.a) | (UCASE(t1.a)=UCASE(t2.a)) | HEX(t1.a) | HEX(t2.a) | HEX(UCASE(t1.a)) | HEX(UCASE(t2.a)) |
+------+------+-------------+-------------+-------------+---------------------------+-----------+-----------+------------------+------------------+
| ͅ    |      |           1 | Ι           |             |                         0 | CD85      | 00        | CE99             | 00               |
| ͅ    |     |           1 | Ι           |            |                         0 | CD85      | 01        | CE99             | 01               |
| ͅ    |     |           1 | Ι           |            |                         0 | CD85      | 02        | CE99             | 02               |
| ͅ    |     |           1 | Ι           |            |                         0 | CD85      | 03        | CE99             | 03               |
| ͅ    |     |           1 | Ι           |            |                         0 | CD85      | 04        | CE99             | 04               |
| ͅ    |     |           1 | Ι           |            |                         0 | CD85      | 05        | CE99             | 05               |
| ͅ    |     |           1 | Ι           |            |                         0 | CD85      | 06        | CE99             | 06               |
| ͅ    |     |           1 | Ι           |            |                         0 | CD85      | 07        | CE99             | 07               |
| ͅ    |    |           1 | Ι           |           |                         0 | CD85      | 08        | CE99             | 08               |
| ͅ    |     |           1 | Ι           |            |                         0 | CD85      | 0E        | CE99             | 0E               |
| ͅ    |     |           1 | Ι           |            |                         0 | CD85      | 0F        | CE99             | 0F               |
| ͅ    |     |           1 | Ι           |            |                         0 | CD85      | 10        | CE99             | 10               |
| ͅ    |     |           1 | Ι           |            |                         0 | CD85      | 11        | CE99             | 11               |
| ͅ    |     |           1 | Ι           |            |                         0 | CD85      | 12        | CE99             | 12               |
| ͅ    |     |           1 | Ι           |            |                         0 | CD85      | 13        | CE99             | 13               |
| ͅ    |     |           1 | Ι           |            |                         0 | CD85      | 14        | CE99             | 14               |
| ͅ    |     |           1 | Ι           |            |                         0 | CD85      | 15        | CE99             | 15               |
| ͅ    |     |           1 | Ι           |            |                         0 | CD85      | 16        | CE99             | 16               |
| ͅ    |     |           1 | Ι           |            |                         0 | CD85      | 17        | CE99             | 17               |
| ͅ    |     |           1 | Ι           |            |                         0 | CD85      | 18        | CE99             | 18               |
| ͅ    |     |           1 | Ι           |            |                         0 | CD85      | 19        | CE99             | 19               |
| ͅ    | �    |           1 | Ι           | �           |                         0 | CD85      | 1A        | CE99             | 1A               |
| ͅ    |            1 | Ι           |                          0 | CD85      | 1B        | CE99             | 1B               |
| ͅ    |     |           1 | Ι           |            |                         0 | CD85      | 1C        | CE99             | 1C               |
| ͅ    |     |           1 | Ι           |            |                         0 | CD85      | 1D        | CE99             | 1D               |
| ͅ    |     |           1 | Ι           |            |                         0 | CD85      | 1E        | CE99             | 1E               |
| ͅ    |     |           1 | Ι           |            |                         0 | CD85      | 1F        | CE99             | 1F               |
| ͅ    |      |           1 | Ι           |             |                         0 | CD85      | 20        | CE99             | 20               |
| ı    | I    |           0 | I           | I           |                         1 | C4B1      | 49        | 49               | 49               |
| ı    | i    |           0 | I           | I           |                         1 | C4B1      | 69        | 49               | 49               |
| ͅ    |     |           1 | Ι           |            |                         0 | CD85      | 7F        | CE99             | 7F               |
| ͅ    |     |           1 | Ι           |            |                         0 | CD85      | C280      | CE99             | C280             |
| ͅ    |     |           1 | Ι           |            |                         0 | CD85      | C281      | CE99             | C281             |
| ͅ    |     |           1 | Ι           |            |                         0 | CD85      | C282      | CE99             | C282             |
| ͅ    |     |           1 | Ι           |            |                         0 | CD85      | C283      | CE99             | C283             |
| ͅ    | 
            |           1 | Ι           | 
                                                     |                         0 | CD85      | C284      | CE99             | C284             |
| ͅ    |     |           1 | Ι           |            |                         0 | CD85      | C286      | CE99             | C286             |
| ͅ    |     |           1 | Ι           |            |                         0 | CD85      | C287      | CE99             | C287             |
| ͅ    |     |           1 | Ι           |            |                         0 | CD85      | C288      | CE99             | C288             |
| ͅ    | 	    |           1 | Ι           | 	           |                         0 | CD85      | C289      | CE99             | C289             |
| ͅ    |     |           1 | Ι           |            |                         0 | CD85      | C28A      | CE99             | C28A             |
| ͅ    |     |           1 | Ι           |            |                         0 | CD85      | C28B      | CE99             | C28B             |
| ͅ    |     |           1 | Ι           |            |                         0 | CD85      | C28D      | CE99             | C28D             |        | 
| ͅ    |     |           1 | Ι           |            |                         0 | CD85      | C28E      | CE99             | C28E             |
| ͅ    |     |           1 | Ι           |            |                         0 | CD85      | C28F      | CE99             | C28F             |
| ͅ    |     |           1 | Ι           |            |                         0 | CD85      | C291      | CE99             | C291             |
| ͅ    |     |           1 | Ι           |            |                         0 | CD85      | C292      | CE99             | C292             |
| ͅ    |     |           1 | Ι           |            |                         0 | CD85      | C293      | CE99             | C293             |
| ͅ    |     |           1 | Ι           |            |                         0 | CD85      | C294      | CE99             | C294             |
| ͅ    |     |           1 | Ι           |            |                         0 | CD85      | C295      | CE99             | C295             |
| ͅ    |     |           1 | Ι           |            |                         0 | CD85      | C296      | CE99             | C296             |
| ͅ    |     |           1 | Ι           |            |                         0 | CD85      | C297      | CE99             | C297             |
| ͅ    |     |           1 | Ι           |            |                         0 | CD85      | C299      | CE99             | C299             |
| ͅ    |    |           1 | Ι           |           |                         0 | CD85      | C29A      | CE99             | C29A             |
| ͅ    |            1 | Ι           |                          0 | CD85      | C29B      | CE99             | C29B             |
| ͅ    |     |           1 | Ι           |            |                         0 | CD85      | C29C      | CE99             | C29C             |
| ͅ    |     | ͅ    |           1 |            | Ι           |                         0 | 18        | CD85      | 18               | CE99             |
|     | ͅ    |           1 |            | Ι           |                         0 | 19        | CD85      | 19               | CE99             |
| �    | ͅ    |           1 | �           | Ι           |                         0 | 1A        | CD85      | 1A               | CE99             |
|  ͅ    |           1 |  Ι           |                         0 | 1B        | CD85      | 1B               | CE99             |
|     | ͅ    |           1 |            | Ι           |                         0 | 1C        | CD85      | 1C               | CE99             |
|     | ͅ    |           1 |            | Ι           |                         0 | 1D        | CD85      | 1D               | CE99             |
|     | ͅ    |           1 |            | Ι           |                         0 | 1E        | CD85      | 1E               | CE99             |
|     | ͅ    |           1 |            | Ι           |                         0 | 1F        | CD85      | 1F               | CE99             |
|      | ͅ    |           1 |             | Ι           |                         0 | 20        | CD85      | 20               | CE99             |
|     | ͅ    |           1 |            | Ι           |                         0 | 7F        | CD85      | 7F               | CE99             |
|     | ͅ    |           1 |            | Ι           |                         0 | C280      | CD85      | C280             | CE99             |
|     | ͅ    |           1 |            | Ι           |                         0 | C281      | CD85      | C281             | CE99             |
|     | ͅ    |           1 |            | Ι           |                         0 | C282      | CD85      | C282             | CE99             |
|     | ͅ    |           1 |            | Ι           |                         0 | C283      | CD85      | C283             | CE99             |
| 
      | ͅ    |           1 | 
                                       | Ι           |                         0 | C284      | CD85      | C284             | CE99             |
|     | ͅ    |           1 |            | Ι           |                         0 | C286      | CD85      | C286             | CE99             |
|     | ͅ    |           1 |            | Ι           |                         0 | C287      | CD85      | C287             | CE99             |
|     | ͅ    |           1 |            | Ι           |                         0 | C288      | CD85      | C288             | CE99             |
| 	    | ͅ    |           1 | 	           | Ι           |                         0 | C289      | CD85      | C289             | CE99             |
|     | ͅ    |           1 |            | Ι           |                         0 | C28A      | CD85      | C28A             | CE99             |
|     | ͅ    |           1 |            | Ι           |                         0 | C28B      | CD85      | C28B             | CE99             |
|     | ͅ    |           1 |            | Ι           |                         0 | C28D      | CD85      | C28D             | CE99             |
|     | ͅ    |           1 |            | Ι           |                         0 | C28E      | CD85      | C28E             | CE99             |
|     | ͅ    |           1 |            | Ι           |                         0 | C28F      | CD85      | C28F             | CE99             |
|     | ͅ    |           1 |            | Ι           |                         0 | C291      | CD85      | C291             | CE99             |
|     | ͅ    |           1 |            | Ι           |                         0 | C292      | CD85      | C292             | CE99             |
|     | ͅ    |           1 |            | Ι           |                         0 | C293      | CD85      | C293             | CE99             |
|     | ͅ    |           1 |            | Ι           |                         0 | C294      | CD85      | C294             | CE99             |
|     | ͅ    |           1 |            | Ι           |                         0 | C295      | CD85      | C295             | CE99             |
|     | ͅ    |           1 |            | Ι           |                         0 | C296      | CD85      | C296             | CE99             |
|     | ͅ    |           1 |            | Ι           |                         0 | C297      | CD85      | C297             | CE99             |
|     | ͅ    |           1 |            | Ι           |                         0 | C299      | CD85      | C299             | CE99             |
|    | ͅ    |           1 |           | Ι           |                         0 | C29A      | CD85      | C29A             | CE99             |
|  ͅ    |           1 |  Ι           |                         0 | C29B      | CD85      | C29B             | CE99             |
|     | ͅ    |           1 |            | Ι           |                         0 | C29C      | CD85      | C29C             | CE99             |
| 1814 rows in set (27 min 46.714 sec)

