Skip to content

Latest commit

 

History

History
82 lines (64 loc) · 3.42 KB

File metadata and controls

82 lines (64 loc) · 3.42 KB
description DBCC DROPCLEANBUFFERS (Transact-SQL)
title DBCC DROPCLEANBUFFERS (Transact-SQL)
ms.custom
ms.date 07/16/2017
ms.prod sql
ms.prod_service sql-data-warehouse, pdw, sql-database
ms.reviewer
ms.technology t-sql
ms.topic language-reference
f1_keywords
DROPCLEANBUFFERS
DBCC_DROPCLEANBUFFERS_TSQL
DROPCLEANBUFFERS_TSQL
DBCC DROPCLEANBUFFERS
dev_langs
TSQL
helpviewer_keywords
clean buffers
cold buffer cache
buffer pools [SQL Server]
dropping buffers
removing buffers
DBCC DROPCLEANBUFFERS statement
ms.assetid a4121927-f2ce-4926-aa2c-9b1519dac048
author pmasl
ms.author umajay
monikerRange >=aps-pdw-2016||=azure-sqldw-latest||>=sql-server-2016||=sqlallproducts-allversions||>=sql-server-linux-2017||=azuresqldb-mi-current

DBCC DROPCLEANBUFFERS (Transact-SQL)

[!INCLUDE sql-asdbmi-asa-pdw]

Removes all clean buffers from the buffer pool, and columnstore objects from the columnstore object pool.

Topic link icon Transact-SQL Syntax Conventions

Syntax

Syntax for [!INCLUDEssNoVersion]:

DBCC DROPCLEANBUFFERS [ WITH NO_INFOMSGS ]  

Syntax for [!INCLUDEssSDW] and [!INCLUDEssPDW]:

DBCC DROPCLEANBUFFERS ( COMPUTE | ALL ) [ WITH NO_INFOMSGS ]  

[!INCLUDEsql-server-tsql-previous-offline-documentation]

Arguments

WITH NO_INFOMSGS
Suppresses all informational messages. Informational messages are always suppressed on [!INCLUDEssSDW] and [!INCLUDEssPDW].

COMPUTE
Purge the data cache in memory from each Compute node.

ALL
Purge the data cache in memory from each Compute node and from the Control node. This is the default if you do not specify a value.

Remarks

Use DBCC DROPCLEANBUFFERS to test queries with a cold buffer cache without shutting down and restarting the server. To drop clean buffers from the buffer pool and columnstore objects from the columnstore object pool, first use CHECKPOINT to produce a cold buffer cache. This forces all dirty pages for the current database to be written to disk and cleans the buffers. After you do this, you can issue DBCC DROPCLEANBUFFERS command to remove all buffers from the buffer pool.

Result Sets

DBCC DROPCLEANBUFFERS on [!INCLUDEssNoVersion] returns:

DBCC execution completed. If DBCC printed error messages, contact your system administrator.  

Permissions

Requires membership in the sysadmin fixed server role for [!INCLUDEssNoVersion] and [!INCLUDEssPDW].
Requires membership in the DB_OWNER fixed server role for [!INCLUDEssSDW].

See Also

DBCC (Transact-SQL)
CHECKPOINT (Transact-SQL)