Explaining PostgreSQL EXPLAIN

Hero image for Explaining PostgreSQL EXPLAIN
This is an external article made in collaboration with another source. Click the button below the view the whole article.

EXPLAIN is a command we prepend to queries to tell us what operations PostgreSQL plans to run for that query, how many rows each operation touches in the database(s), and how long those operations take. EXPLAIN is the go-to performance diagnostic tool for discovering what is causing a query to run slowly.

Explaining PostgreSQL EXPLAIN