Click to Rate and Give Feedback
TechNet
TechNet Library
SQL Server
SQL Server 2008
Database Engine
Development
 How to: Drop a Database Snapshot (T...
Community Content
In this section
Statistics Annotations (0)
Collapse All/Expand All Collapse All
Other versions are also available for the following:
SQL Server 2008 Books Online (October 2009)
How to: Drop a Database Snapshot (Transact-SQL)

Any user in the database with DROP DATABASE permissions can drop a database snapshot by using Transact-SQL.

When you drop a database snapshot, all user connections to it are terminated.

  1. Identify the database snapshot that you want to drop. You can view the snapshots on a database in SQL Server Management Studio (see How to: View a Database Snapshot (SQL Server Management Studio)).

  2. Issue a DROP DATABASE statement, specifying the name of the database snapshot to be dropped.

This example drops a database snapshot named SalesSnapshot0600, without affecting the source database.

DROP DATABASE SalesSnapshot0600

Any user connections to SalesSnapshot0600 are terminated, and all of the NTFS file system sparse files used by the snapshot are deleted. For information about the use of sparse files by database snapshots, see How Database Snapshots Work.

Tags What's this?: Add a tag
Community Content   What is Community Content?
Add new content RSS  Annotations
Processing
© 2009 Microsoft Corporation. All rights reserved. Terms of Use | Trademarks | Privacy Statement
Page view tracker