Restore to New Location

  • Hello,

    I have a situation in which I need to recover a database up to a 10:00am log to recover a specific record for a specific user. I have to do this without effecting the data (since 10:00am) of the other users.

    I thought If I could restore the database up to 10:00am to a different location, I could get the one record I need, export it, and bring the record back into the database.

    I looked at the BOL information and I understand I can do something like this:

    RESTORE DATABASE MyNwind

       FROM MyNwind_1

       WITH NORECOVERY,

       MOVE 'MyNwind_data_1' TO 'D:\MyData\MyNwind_data_1.mdf',

       MOVE 'MyNwind_data_2' TO 'D:\MyData\MyNwind_data_2.nd

    and this would restore the mdf file to a new location. If I do this, will the SQL Server connection to the database point to the new location (I don't want this to happen)?

    So basically, I need a copy of the database restored up to 10:00am this morning without effecting the production database.

    Would the above code be the route to go?

    Thank you for your help!

    CSDunn

  • You need to be sure you specify a different databaes name. You want to create a "new" database by restoring the original database's backup as a new database with the files in a new location.

Viewing 2 posts - 1 through 1 (of 1 total)

You must be logged in to reply to this topic. Login to reply