在某些情况下,or条件可以避免全表扫描的。
1 .where 语句里面如果带有or条件, myisam表能用到索引, innodb不行。
2)innodb表:
1 row in set (0.00 sec)