Was this page helpful?
Your feedback about this content is important. Let us know what you think.
Additional feedback?
1500 characters remaining
Export (0) Print
Expand All
Expand Minimize

DROP DATABASE AUDIT SPECIFICATION (Transact-SQL)

Applies To: SQL Server 2014, SQL Server 2016 Preview

Topic Status: Some information in this topic is preview and subject to change in future releases. Preview information describes new features or changes to existing features in Microsoft SQL Server 2016 Community Technology Preview 2 (CTP2).

Drops a database audit specification object using the SQL Server Audit feature. For more information, see SQL Server Audit (Database Engine).

Applies to: SQL Server (SQL Server 2008 through current version).

Topic link icon Transact-SQL Syntax Conventions

DROP DATABASE AUDIT SPECIFICATION audit_specification_name
[ ; ]

audit_specification_name

Name of an existing audit specification object.

A DROP DATABASE AUDIT SPECIFICATION removes the metadata for the audit specification, but not the audit data collected before the DROP command was issued. You must set the state of a database audit specification to OFF using ALTER DATABASE AUDIT SPECIFICATION before it can be dropped.

Users with the ALTER ANY DATABASE AUDIT permission can drop database audit specifications.

A. Dropping a Database Audit Specification

The following example drops an audit called HIPAA_Audit_DB_Specification.

DROP DATABASE AUDIT SPECIFICATION HIPAA_Audit_DB_Specification;
GO

For a full example of creating an audit, see SQL Server Audit (Database Engine).

Community Additions

ADD
Show:
© 2015 Microsoft