MSSQL 備份資料庫還原

DukeCheng發表於2015-06-28

-- 完整還原
RESTORE DATABASE XXXX
FROM DISK = 'd:\XXXX.bak'
WITH MOVE 'XXXX' TO 'D:\MSSQL\Data\XXXX.mdf',
MOVE 'XXXX_Log' TO 'D:\MSSQL\Data\XXXX.ldf',
REPLACE,NORECOVERY;
GO

 

檢視備份檔案資訊

RESTORE FILELISTONLY FROM DISK = N'd:\XXXX.bak';

相關文章