ssqlserver建立数据库快照

IF EXISTS (SELECT * FROM sys.databases WHERE NAME='DATABASE_SS')
BEGIN
    DROP DATABASE DATABASE_SS;
END

GO

CREATE DATABASE DATABASE_SS ON

(NAME = DATABASE,

 FILENAME = 'D:\SQLData_SS\DATABASE.SS')

AS SNAPSHOT OF DATABSE

GO

 

posted @ 2021-10-28 15:09  芈璐  阅读(73)  评论(0编辑  收藏  举报