AI engineering glossary · SQL databases

What is EXPLAIN?

EXPLAIN (also called EXPLAIN ANALYZE): A command that shows the execution plan for a query without, or with (EXPLAIN ANALYZE), running it. The output lists steps, estimated costs and row counts, and with ANALYZE the real timings.

Level: intermediateTopic: SQL databases

EXPLAIN: an example

EXPLAIN ANALYZE SELECT * FROM orders WHERE customer_id = 42; reveals whether an index or full scan was used.

Related terms

More SQL databases terms

Where you learn it

EXPLAIN is part of the AI Engineering Program, which teaches it with notes, a hands-on lab and an exam. The first lesson is free.

Before you go

Take the cheat sheet with you

One free PDF: the key AI-engineering terms, formulas and Python idioms. No spam; unsubscribe any time.