http://rainkid.blog.163.com/blog/static/16514084020108905632961/
mysql>explain select * from table;
+----+-------------+-------+------+---------------+------+---------+------+------+-------+
| id | select_type | table | type | possible_keys | key | key_len | ref | rows | Extra |
+----+-------------+-------+------+---------------+------+---------+------+------+-------+
table #显示该语句涉及的表
type #反映语句的质量,优-->差:const > eq_reg > ref > range > indexhe > ALL
possible_keys #存在表中的所有索引
key #使用到的索引
key_len #索引长度,越短越好
ref #显示索引的那一列被用到
rows #语句返回的数据行数
extra #语句查询情况的详细信息