Duplicate a database with SQL Server Express 2008

Following my previous post, here is the same script for SQL Server Express 2008: USE master GO — the original database (use ‘SET @DB = NULL’ to disable backup) DECLARE @DB varchar(200) SET @DB = ‘MyDB’ — the backup filename DECLARE @BackupFile varchar(2000) SET @BackupFile = ‘c:\temp\mydb.dat’ — the new database name DECLARE @TestDB varchar(200) […]

READ MORE