--查看当前的mysql版本是否支持

show variables like 'profiling%';

 

--默认关闭,使用前需要开启
set profiling=on;

 

--运行耗时久的sql

SELECT 
DISTINCT
io.housing_id 
FROM
t_device_report_message re
LEFT JOIN t_device_io io ON re.device_id = io.device_id 
WHERE
io.housing_id is not null
View Code

相关文章:

  • 2021-10-10
  • 2021-12-10
  • 2021-12-10
  • 2021-12-10
  • 2021-12-20
  • 2021-11-12
猜你喜欢
  • 2022-02-28
  • 2021-08-21
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-04-08
  • 2021-05-29
相关资源
相似解决方案