Sample Header Ad - 728x90

What are the advantages and disadvantages of inspecting the Plan Cache rather than the Query Store?

2 votes
1 answer
645 views
The Plan Cache and the Query Store are not the same, even [for the same query](https://www.scarydba.com/2018/11/19/query-store-and-plan-cache-plans-compared/) . When hunting for performance or monitoring information on a specific query or set of related queries, what are the advantages/disadvantages of each? The general impression that my online research indicates is that the Query Store can be queried faster than the Plan Cache (I'm not sure why) and that its entries tend to last much longer (this is configurable), but I have found nothing said about situations where the Plan Cache is superior to the Query Store. Assume that I do not care about the features that SQL Server 2017 and 2022 introduced that use Query Store for automatic performance tuning. Instead assume that I am comparing the Query Store and Plan Cache for the purposes of tasks that both can do.
Asked by J. Mini (1237 rep)
Jan 13, 2024, 08:45 PM
Last activity: Feb 1, 2024, 07:00 PM