profile用法

#查看profiling结果
 | starting             | 0.020203 |
 | checking permissions | 0.000026 |
 | Opening tables       | 0.000036 |
 | init                 | 0.000099 |
 | System lock          | 0.000092 |
 | optimizing           | 0.000038 |
 | statistics           | 0.000123 |
 | preparing            | 0.000043 |
 | Sorting result       | 0.000025 |
 | executing            | 0.000023 |
 | Sending data         | 0.000045 |
 | Creating sort index  | 0.941434 |



1.一次SQL优化过程中的分析过程
http://wangleide414.iteye.com/blog/2265843
2.discuz!热帖翻页优化

3.分页优化
http://imysql.com/2014/07/26/mysql-optimization-case-paging-optimize.shtml