mysql索引分类 性能分析
索引分类


性能分析
-
查看执行频次
show global status like 'Com_______' -
查看慢查询日志是否开启
show variables like 'slow_query_log'; -
查看是否支持查看详情
select @@have_profiling -
是否打开
select @@profiling; -
打开
set profiling=1 -
查看详情
show profiles; -
指定行的sql语句在各阶段的耗时
show profile for query 行号 -
执行计划
explain SQL语句


浙公网安备 33010602011771号