Commit 094250d
sp_BlitzCache: scope NumberOfPlans UPDATE to current SPID
##BlitzCacheProcs is a global temp table; with concurrent sp_BlitzCache
runs it can hold rows for multiple SPIDs. The UPDATE that sets
NumberOfPlans / NumberOfDistinctPlans didn't have a SPID predicate, so it
would touch other sessions' rows too (and cause unnecessary blocking).
Add the standard @@spid filter, matching the two UPDATEs immediately
above it at lines 3041 and 3107.
Addresses review feedback on BrentOzarULTD#3940.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>1 parent ffb813b commit 094250d
1 file changed
Lines changed: 1 addition & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3181 | 3181 | | |
3182 | 3182 | | |
3183 | 3183 | | |
| 3184 | + | |
3184 | 3185 | | |
3185 | 3186 | | |
3186 | 3187 | | |
| |||
0 commit comments