Query plan
A step-by-step abstract specification of how the database will physically execute a SQL query.
A query plan specifies the operations in order: which indexes to use, how to join tables, which pages to read first, and when to acquire locks. The optimizer assigns costs to each plan based on disk I/O, row counts, and buffer hits, then selects the cheapest.
Developers can often inspect the plan with EXPLAIN or ANALYZE to understand why a query is slow. A bad plan is often fixable by adding an index or updating table statistics.