© The Author(s), under exclusive license to APress Media, LLC, part of Springer Nature 2022
G. FritcheySQL Server 2022 Query Performance Tuninghttps://doi.org/10.1007/978-1-4842-8891-7_7

7. Execution Plan Cache Behavior

Grant Fritchey1  
(1)
Grafton, MA, USA
 

The query optimization process is expensive. Because of this, SQL Server keeps the execution plans it has created in memory in order to reuse those plans. The space where these plans are stored is referred to as the plan cache. Understanding how plans get into, and out of, the plan cache is an important part of query tuning. In this chapter, I will walk you through the mechanisms you can use to monitor and observe the plan cache and plan reuse.

I will cover the following topics:
  • Querying the plan ...

Get SQL Server 2022 Query Performance Tuning: Troubleshoot and Optimize Query Performance now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.