from what i know, if i execute 'DBCC FREEPROCCACHE' and 'DBCC DROPCLEANBUFFERS', the buffer of entire server will be cleanup. i wonder if there's anyway to cleanup buffer of specified database only. therefore, query for other databases will not be affected.
You can clear all execution plans from a single database using DBCC FLUSHPROCINDB(<db_id>)
. I'm not aware of any similar command to clear specific pages from the buffer cache.
However, you can set the database offline momentarily and then back online to clear both plan and buffer caches for a database if the situation allows for this.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With