简体   繁体   English

如何在SQL Server 2008 R2中创建数据库快照

[英]How to create a database snapshot in SQL Server 2008 R2

I used the below command to create a database snapshot in SQL Server 2008 R2: 我使用以下命令在SQL Server 2008 R2中创建数据库快照:

  CREATE DATABASE "dbss" ON  (
  NAME = "os-file-name",
  FILENAME = 'path')
  AS SNAPSHOT OF "dbName";
  GO

I got this error: 我收到了这个错误:

Database Snapshot is not supported on Standard Edition (64-bit). Standard Edition(64位)不支持数据库快照。

Does anyone knows how can I create a database snapshot in SQL Server 2008 R2? 有谁知道如何在SQL Server 2008 R2中创建数据库快照?

Database Snapshot is a feature of the Enterprise Edition and the 2008 Developer Edition. 数据库快照是Enterprise Edition和2008 Developer Edition的一项功能。

Besides that there is only little use of Snapshots for a "common user". 除此之外,对于“普通用户”,很少使用快照。 Most things can be done with a backup too. 大多数事情也可以通过备份来完成。

Main purpose for snapshots are expensive queries on rapidly changing data. 快照的主要目的是对快速变化的数据进行昂贵的查询。 If you got a huge database and need to execute a query for a report that takes some time there is the danger that data may change while the query / procedure fetches data for the report. 如果您有一个庞大的数据库并且需要为报告执行查询需要一些时间,那么在查询/过程获取报告数据时,数据可能会发生变化。 In this case you need snapshots. 在这种情况下,您需要快照。 There you can query all your data without having problems with changing data. 在那里,您可以查询所有数据,而无需更改数据。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM