none
SQL Server 2000 - Restore command specifying the location for mdf and ldf files?

    Question

  • Hi, I have an old server with SQL Server 2000.

    I have a "c:\db1.bak"
     which needs to be restored in such a way that mdf and ldf files are saved in "X:/Data"

    If someone can please post the command that will be great!

    Thanks so much.

    Friday, July 26, 2013 4:16 AM

Answers

  • TRY,

    RESTORE DATABASE DB2
    FROM DISK = 'C:\DB1.bak'
    WITH MOVE 'DB1_Data_logicalName' TO 'X:\DATE\DB2_DATA.mdf',
    MOVE 'DB1_log_logicalName' TO 'X:\DATA\DB2_LOG.ldf',REPLACE


    Regards, RSingh


    Friday, July 26, 2013 4:31 AM

All replies