Quantcast
Channel: SQLServerCentral » SQL Server 2014 » Development - SQL Server 2014 » Latest topics
Viewing all articles
Browse latest Browse all 3145

Script out multiple differential restore backups

$
0
0
I am working on a migration of SQL 2012 to 2014 and I am trying to eliminate down time as much as possible. I have worked with other on this forum on getting a script to restore all my system database 500+ and I decided I want to put them all in to NORECOVERY so then I can then reduce the down time to the time it takes to make a differential backup and restore it on the new server versus taking a full backup during the downtime which will take a while. So my question is, there any way have a script run though my Differenttial folder and produce multiple restore lines like this one. I got this from scripting out a differential restore from a NORECOVERY full backup[code="other"]RESTORE DATABASE [db] FROM DISK = N'F:\path\to\full\backup.bak' WITH FILE = 1, NORECOVERY, NOUNLOAD, STATS = 5RESTORE DATABASE [db] FROM DISK = N'F:\path\to\diff\backup.bak' WITH FILE = 1, NOUNLOAD, STATS = 5GO[/code]

Viewing all articles
Browse latest Browse all 3145

Trending Articles