QUESTION 15 OF 15

How do you investigate a slow PostgreSQL query?

Reveal the answer and explore the explanation.

15
MediumHigh priority

How do you investigate a slow PostgreSQL query?

Answer
Answer

Displays a database query plan; EXPLAIN ANALYZE executes the statement and reports observed execution statistics.

Practical example

Investigate whether a query uses an index or scans the whole table.

Reference: Further reading ↗

Last 30 min revisionHigh-yield interview Q&As