EXPLAIN in the Slow Query Log
You are viewing an old version of this article. View
the current version here.
Starting from MariaDB 10.0.4, it is possible to have EXPLAIN output printed in the slow query log.
Switching it on
EXPLAIN can be switched on by specifying "explain
" keyword in the log_slow_verbosity
system variable. Alternatively, you can specify in the log-slow-verbosity
command line argument.
[mysqld] log-slow-verbosity=query_plan,explain
How it looks like
When explain printing is on, slow query log entries look like this:
Comments
Comments loading...
Content reproduced on this site is the property of its respective owners,
and this content is not reviewed in advance by MariaDB. The views, information and opinions
expressed by this content do not necessarily represent those of MariaDB or any other party.