SQLServer: Clone database

 RESTORE DATABASE [identityiq_copy] 

FROM  DISK = N'G:\SQLBackup\identityiq\identityiq_backup_2024_11_14_010001_0064765.bak' WITH  FILE = 1,  
MOVE N'identityiq' TO N'I:\SQLData\identityiq_copy.mdf',  
MOVE N'identityiq_log' TO N'J:\SQLLog\identityiq_copy.ldf',  
NOUNLOAD,  REPLACE,  STATS = 10
GO

Comments

Popular posts from this blog

Oracle: To clean up WRI$_ADV_OBJECTS