This sample works only with SQL Server 2005 and SQL Server 2008. It will not work with any version of SQL Server earlier than SQL Server 2005.
The purpose of the DatabaseSnapshot
sample is to demonstrate the database snapshot capabilities of SQL Server. For more information, see "Database Snapshots" in SQL Server Books Online.
A database snapshot is a read-only, static view of a database. This database is called the source database. Each database snapshot is transaction-consistent with the source database at the moment of the snapshot's creation. A snapshot persists until it
is explicitly dropped by the database owner. Multiple snapshots can exist on a database. This sample creates a new database snapshot of the
Before you run this sample, perform the following tasks:
- Install SQL Server and make sure you include the following components:
- The Database Engine
- SQL Server Management Studio
- Download the AdventureWorks (OLTP) sample database and SQL Server Database Engine samples available at the Microsoft SQL Server
Samples and Community Projects Web site.
Running the Sample
Installing and Running the Sample
- From Management Studio, open the file CreateDatabaseSnapshot.sql script located in the C:\Program Files\Microsoft SQL Server\100\Samples\Engine\Administration\DatabaseSnapshot\Scripts folder, and click
Execute. © 2008 Microsoft Corporation. All rights reserved.