March 23, 2013 at 3:53 pm
RESTORE DATABASE <new database name> FROM DISK = <backup location>
WITH MOVE ....
Probably easier to do with T-SQL than the GUI.
Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability
March 24, 2013 at 4:41 pm
Now the new db is stuck as Restoring. This is the query that I ran, and the message that it delivered after. Did I miss something? I've definitely waited long enough.
RESTORE DATABASE TestDB
FROM DISK = 'D:\Backup\backup.bak'
WITH NORECOVERY,
MOVE 'DateFile' TO 'D:\Program Files\Microsoft SQL Server\MSSQL11.MSSQLSERVER\MSSQL\DATA\TestDB.mdf',
MOVE 'LogFile_Log' TO 'D:\Program Files\Microsoft SQL Server\MSSQL11.MSSQLSERVER\MSSQL\DATA\TestDB.ldf';
GO
[font="Courier New"]Processed 379192 pages for database 'TestDB', file 'DateFile' on file 1.
Processed 5 pages for database 'TestDB', file LogFile_log' on file 1.
RESTORE DATABASE successfully processed 379197 pages in 79.610 seconds (37.212 MB/sec).[/font]
March 24, 2013 at 10:21 pm
RESTORE DATABASE TestDB
FROM DISK = 'D:\Backup\backup.bak'
WITH NORECOVERY,
MOVE 'DateFile' TO 'D:\Program Files\Microsoft SQL Server\MSSQL11.MSSQLSERVER\MSSQL\DATA\TestDB.mdf',
MOVE 'LogFile_Log' TO 'D:\Program Files\Microsoft SQL Server\MSSQL11.MSSQLSERVER\MSSQL\DATA\TestDB.ldf';
GO
In the RESTORE statement, you specified NORECOVERY, which leaves the database in a state where additional log files may be restored. If you are done restoring the database, then you need to recover the database:
RESTORE DATABASE TestDB
WITH RECOVERY
Eddie Wuerch
MCM: SQL
March 25, 2013 at 9:34 am
Ha! Wow, thanks for being patient with my me. That fixed it.
Much appreciated everyone!
Viewing 4 posts - 1 through 5 (of 5 total)
You must be logged in to reply to this topic. Login to reply