Home  >  Q&A  >  body text

MYSQL: Best choice for accent-sensitive but case-insensitive UTF settings

For example, ἐν or Ἐν are the same but should be distinguished from ἕν/Ἓν. I tried utf8_bin which seems to be the closest but is also case sensitive.

P粉754473468P粉754473468408 days ago765

reply all(1)I'll reply

  • P粉481815897

    P粉4818158972023-09-08 10:18:11

    mysql> select 'ἐν' = 'Ἐν' collate utf8mb4_0900_as_ci;
    +----------------------------------------------+
    | 'ἐν' = 'Ἐν' collate utf8mb4_0900_as_ci       |
    +----------------------------------------------+
    |                                            1 |
    +----------------------------------------------+
    
    mysql> select 'ἐν' = 'ἕν' collate utf8mb4_0900_as_ci;
    +----------------------------------------------+
    | 'ἐν' = 'ἕν' collate utf8mb4_0900_as_ci       |
    +----------------------------------------------+
    |                                            0 |
    +----------------------------------------------+

    reply
    0
  • Cancelreply