CRUD-区分大小写查询
where
查询
mysql> select * from t_emp where ename = "smith";
+-------+-------+-------+------+------------+--------+------+--------+
| empno | ename | job | mgr | hiredate | sal | comm | deptno |
+-------+-------+-------+------+------------+--------+------+--------+
| 7369 | SMITH | CLERK | 7902 | 1980-12-17 | 800.00 | NULL | 20 |
+-------+-------+-------+------+------------+--------+------+--------+
正常的where
语句对字符串的查询都是不区分大小写的
区分大小写查询
mysql> select * from t_emp where binary ename = "smith";
Empty set (0.00 sec)
可以通过binary
关键字进行查询