SQL Server Interview Question #132

What is an execution plan?

Indexes & Query Performance Senior Advanced

Detailed Explanation

An execution plan shows how SQL Server intends to or actually executes a query. It contains physical operators such as Index Seek, Index Scan, Table Scan, Nested Loops, Hash Match, Sort, and Key Lookup.

Estimated plans are generated without executing the query. Actual execution plans include runtime information after execution. Plans are essential for diagnosing performance because the SQL text alone does not reveal the optimizer's chosen access strategy.