RID or Key Lookups in the Plan Cache
sp_Blitz® Result: RID or Key Lookups in the Plan Cache
If you use @CheckProcedureCache = 1, then sp_Blitz® looks at the top 20-50 most resource-intensive queries in the plan cache. It examines them for common anti-patterns that cause slow performance, and one of the things it’s looking for is row lookups and key lookups.
Ideally, your most performance-intensive queries use covering indexes rather than doing row lookups – but this isn’t an absolute rule. We just guess that you’re using @CheckProcedureCache = 1 because you’re unhappy with server performance or query performance. Because of that, it’s probably time to look at those queries and examine the cost involved with those row lookups.
TO FIX THE PROBLEM
Examine the plans involved, and then read up on the differences between covering queries and key lookups. Here’s some of our favorite resources on the topic:
- How to Think Like the Engine – free video training course explaining the basics
- How to Tune Indexes and Speed Up SQL Server – more in-depth training course going into much more detail