Read any SQL query in plain English.
Paste a query to see what it does, step by step, in the order the database actually runs it. Plain SQL also flags mistakes that cost people data and hours.
Paste or type a query, then press Ctrl + Enter
Clear
Explain query
Example files
Drag a file onto the page to explain it, or click Open it here . Your own .sql files work the same way: drop one anywhere on the page.
What it checks for Plain SQL reads your query the way a careful reviewer would. Nothing is sent anywhere.
Critical UPDATE or DELETE with no WHERE, which changes every row in the table
Critical Joins with no condition, which pair every row with every other row
Critical = NULL comparisons, which never match anything
Critical Columns in SELECT that aren't grouped or aggregated
Warning Joins that multiply rows and inflate SUM and COUNT totals
Warning A LEFT JOIN quietly turned into an inner join by the WHERE clause
Warning NOT IN with a subquery that can contain NULL
Warning AND and OR mixed without parentheses
Warning SELECT *, and LIMIT without ORDER BY
Tip Functions on columns and leading % wildcards that can't use an index
Plain SQL runs entirely in your browser. The sample database is made-up data.
Built by Ayan Khan