DBCC FREESESSIONCACHE (Transact-SQL)
Applies to: SQL Server (all supported versions) Azure SQL Managed Instance
Flushes the distributed query connection cache used by distributed queries against an instance of Microsoft SQL Server.
DBCC FREESESSIONCACHE [ WITH NO_INFOMSGS ]
To view Transact-SQL syntax for SQL Server 2014 and earlier, see Previous versions documentation.
Suppresses all informational messages.
Requires membership in the sysadmin fixed server role.
The following example flushes the distributed query cache.
USE AdventureWorks2012; GO DBCC FREESESSIONCACHE WITH NO_INFOMSGS; GO