-
-
Notifications
You must be signed in to change notification settings - Fork 1.9k
10.11 mdev 33309 no r_other_time_ms shown in analyze format=json output for update or delete queries #4302
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
10.11 mdev 33309 no r_other_time_ms shown in analyze format=json output for update or delete queries #4302
Conversation
d032815
to
3ef1e17
Compare
insert into t2 select * from t1; | ||
|
||
--source include/analyze-format.inc | ||
analyze format=json |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please add --echo # Top-level query block must have r_table_time_ms and r_other_time_ms
where t1.pk > (select max(a) from t2 where t2.pk+1 = t1.pk+1 ) - 10; | ||
|
||
--source include/analyze-format.inc | ||
analyze format=json |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please also add a comment like requested above.
In commit comments, instead of "This PR does X" it is common to write "Do X"
|
I was wondering where does the update time get billed to analyze format=json update t1 set a=a+1 where t1.pk > 994; and paused it in ha_innobase::update() for a while. | {
"query_optimization": {
"r_total_time_ms": 0.814298762
},
"query_block": {
"select_id": 1,
"r_total_time_ms": 20056.984,
"table": {
"update": 1,
"table_name": "t1",
"access_type": "range",
"possible_keys": ["PRIMARY"],
"key": "PRIMARY",
"key_length": "4",
"used_key_parts": ["pk"],
"rows": 6,
"r_rows": 6,
"r_filtered": 100,
"r_table_time_ms": 20056.77929,
"r_other_time_ms": 0.166702744,
"r_engine_stats": {
"pages_accessed": 11,
"pages_updated": 15
},
"attached_condition": "t1.pk > 994"
}
}
} | FK updates will be billed to the |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please address the input above and then the patch is ok.
3ef1e17
to
4208851
Compare
…r_time_ms Single-table UPDATE/DELETEs only show r_total_time_ms in top-level query block. Replace it with r_table_time_ms and r_other_time_ms.
6c3101c
to
573d3ad
Compare
Sure, addressed the comments. |
MDEV-33309: for update|delete analyze format=json doesn't show r_other_time_ms
Single-table UPDATE/DELETEs only show r_total_time_ms in top-level query block.
Replace it with r_table_time_ms and r_other_time_ms.