Currently, XenForo does an EXPLAIN on queries to fetch the estimated query plan for various database calls. Recent versions of MySQL (and latest development version of MariaDB) support an "optimizer trace" table which contains the last query's actual execution plan. This feature can be enabled/disabled per session via the
Supporting this feature would give much more accurate debug information for administrators and developers.
Information;
optimizer_trace
session variable, however the enable/disable state appears different between MariaDB & MySQL.Explain
only outputs the estimated execution plan, which can be different if statistics are out of date compared to what the actual optimizer picks when executing the query. Supporting this feature would give much more accurate debug information for administrators and developers.
Information;
Optimizer Trace Overview
Produces a JSON trace with decision info taken by the optimizer during the optimization phase.
mariadb.com
MySQL :: MySQL 5.7 Reference Manual
dev.mysql.com
Upvote
10