© Ed Pollack 2016

Edward Pollack, Dynamic SQL, 10.1007/978-1-4842-1811-2_8

8. Parameter Sniffing

Edward Pollack

(1)Albany, New York, USA

Chapter 6 introduced a number of tools, methods, and tips for performance optimization. A critical component that was briefly discussed was the query plan cache. Whenever a query is executed for the first time, an execution plan is generated by the query optimizer. This process is expensive and therefore it is beneficial to minimize the work that is performed by it. Execution plans are placed into the query plan cache when optimization is complete, where they will remain until sufficient changes occur in execution, available memory, or the underlying data to push that plan out of cache.

This process by which execution ...

Get Dynamic SQL: Applications, Performance, and Security now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.