Explain Query
explainQueryGet an execution plan for a slow SQL query to diagnose performance issues. Understand how tables are scanned, indexes used, and where to add indexes.
Instructions
Return the execution plan for a SQL query to diagnose performance. Use this tool instead of running EXPLAIN directly through readQuery — it provides structured output via EXPLAIN QUERY PLAN.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| query | Yes | The SQL query to explain. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| rows | Yes | Result rows, each a JSON object keyed by a column name. |