一、概念 二、explain 三、sql优化 count(*)包含null值,count(id)不包含null值; 1、子查询优化使用join,不要使用in; 2、group by优化 优化后: 3、索引优化 相关文章: