Oracle
1Z0-888 · Question #56
1Z0-888 Question #56: Real Exam Question with Answer & Explanation
Sign in or unlock 1Z0-888 to reveal the answer and full explanation for question #56. The question stem and answer options stay visible for context.
Performance Tuning
Question
You are investigating the performance of a query which selects data from an InnoDB table. Consider this Performance Schema diagnostics output for the query:
mysql> SELECT event_id, event_name, timer_wait, nesting_event_id, source
FROM (SELECT thread_id, event_id, event_name, timer_wait, nesting_event_id,
source
FROM
performance_schema.events_statements_history_long
WHERE event_id = 8945
UNION ALL
SELECT thread_id, event_id, event_name, timer_wait, nesting_event_id,
source
FROM
performance_schema.events_stages_history_long
WHERE event_id = 8945
UNION ALL
SELECT thread_id, event_id, event_name, timer_wait, nesting_event_id,
source
FROM
performance_schema.events_waits_history_long
WHERE
event_id = 8945 OR event_name <> 'Idle' AND thread_id =
) AS a
ORDER BY
event_id;
+----------+-------------------------------------------------+------------+--------------------+-------------------------------------------+
| event_id | event_name | timer_wait | nesting_event_id | source |
+----------+-------------------------------------------------+------------+--------------------+-------------------------------------------+
| 8944 | stage/sql/select | 960916000 | NULL | sql_parse.cc:1931 |
| 8945 | stage/sql/init | 90045000 | 8944 | sql_parse.cc:1845 |
| 8946 | stage/sql/checking permissions | 47290000 | 8944 | sql_parse.cc:2020 |
| 8947 | stage/sql/checking tables | 3826000 | 8944 | sql_base.cc:4911 |
| 8948 | stage/sql/open | 57268000 | 8944 | sql_parse.cc:3874 |
| 8949 | stage/sql/system lock | 22660000 | 8944 | lock.cc:315 |
| 8950 | stage/sql/optimizing | 1849000 | 8944 | sql_optimizer.cc:1150 |
| 8951 | stage/sql/init/session | 13395156 | 8949 | sql_optimizer.cc:1443 |
| 8952 | wait/synch/mutex/mysys/THR_LOCK::mutex | 294408 | 8951 | /home/pb2/mysql/sql/mysys/thr_mutex.cc:145|
| 8953 | stage/sql/optimizing | 1387000 | 8944 | sql_optimizer.cc:1150 |
| 8954 | stage/sql/init | 345439000 | 8944 | sql_parse.cc:1845 |
| 8955 | wait/io/table/sql/handler | 302137776 | 8954 | handler.cc:202 |
| 8956 | wait/synch/mutex/mysys/THR_LOCK::mutex | 256240 | 8954 | /home/pb2/mysql/sql/mysys/thr_mutex.cc:145|
| 8957 | stage/sql/preparing | 70460000 | 8944 | sql_select.cc:846 |
| 8958 | stage/sql/executing | 7350000 | 8944 | sql_select.cc:1107 |
| 8959 | stage/sql/sending data | 14570000 | 8944 | sql_select.cc:1157 |
| 8960 | stage/sql/end | 4927000 | 8944 | sql_select.cc:1165 |
| 8961 | stage/sql/query end | 1387000 | 8944 | sql_parse.cc:4012 |
| 8962 | stage/sql/closing tables | 6128000 | 8944 | sql_parse.cc:3996 |
| 8963 | stage/sql/freeing items | 5896000 | 8944 | sql_parse.cc:4283 |
| 8964 | stage/sql/cleaning up | 1187000 | 8944 | sql_parse.cc:4404 |
+----------+-------------------------------------------------+------------+--------------------+-------------------------------------------+
Which statement is true about the output?
Options
- AThe time the query took is the sum of all timer_wait values.
- BThe query did not find its table in the table definition cache.
- CThe query read data from the data file rather than directly from the buffer pool.
- DThe event with event_id = 8945 is a child of the event with event_id=8944.
Unlock 1Z0-888 to see the answer
You've previewed enough free 1Z0-888 questions. Unlock 1Z0-888 for full answers, explanations, the timed quiz mode, progress tracking, and the master PDF. Question stem and options stay visible so you can still see what's on the exam.
Topics
#Performance Schema#Query Diagnostics#Table Definition Cache#Query Optimization