Why am I having so much trouble restoring?

  • 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

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass
  • 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]

  • 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

  • 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