可能的复制品: 类大小写敏感
Mysql 忽略了它的 LIKE 比较的大小写。
如何强制它执行区分大小写的 LIKE 比较?
Use LIKE BINARY:
LIKE BINARY
mysql> SELECT 'abc' LIKE 'ABC'; -> 1 mysql> SELECT 'abc' LIKE BINARY 'ABC'; -> 0
Another alternative is to use COLLATE,
COLLATE
SELECT * FROM table1 WHERE columnName like 'a%' COLLATE utf8_bin;