PHPMyAdmin 的“查询已完成”时间与 MySQL 分析信息不同
在 PHPMyAdmin 中使用新的 MySQL 查询分析器版本 2.11.5,我得到以下结果(PNG-version
Status Time
(initialization) 0.00004
Opening tables 0.000059
System lock 0.000003
Table lock 0.000006
init 0.000013
optimizing 0.000004
statistics 0.000015
preparing 0.000012
executing 0.000028
Sending data 0.000129
end 0.000003
query end 0.000002
freeing items 0.000003
closing tables 0.000001
removing tmp table 0.000007
closing tables 0.000002
logging slow query 0.000001
Showing rows 0 - 29 (29,128 total, Query took 1.6200 sec)
)添加这些时间,我得到 0.000328。 我想知道为什么 PHPMyAdmin 报告 1.6200 秒?
Using the new MySQL Query Profiler in PHPMyAdmin version 2.11.5, I got following results (PNG-version)
Status Time
(initialization) 0.00004
Opening tables 0.000059
System lock 0.000003
Table lock 0.000006
init 0.000013
optimizing 0.000004
statistics 0.000015
preparing 0.000012
executing 0.000028
Sending data 0.000129
end 0.000003
query end 0.000002
freeing items 0.000003
closing tables 0.000001
removing tmp table 0.000007
closing tables 0.000002
logging slow query 0.000001
Showing rows 0 - 29 (29,128 total, Query took 1.6200 sec)
When I add those times, I get 0.000328. I'm wondering why PHPMyAdmin reports 1.6200 secs?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
查询分析器不考虑数据在数据库和后端之间移动所需的实际时间。可能还涉及其他因素,但基本上 PHPMyAdmin 记录整个链(可能不是那么准确),而查询分析器仅测量数据库内采取的操作。
Query Profiler doesn't take into account the actual time it takes for the data to move between the database and the back end. There might be other factors involved, but basically PHPMyAdmin records the whole chain (and perhaps not that accurately) whereas Query Profiler only measures the actions taken inside the database.