Can we use "With Move" option from TSQL for System databases

  • Hi .....

    I tried to restore system databases throught TSQL statement. I wanted to move the databases to new location. I know that it works fine when you restore them from Enterprise Manager. However, It did not work for me from TSQL. If somebody knows, can we use "With Move" option in TSQL for system databases to restore them.

    Also, when we need to move or Restore MSDB and Model Databases?

     

    Thanks.

    Burhan

     

  • Yup, WITH MOVE works for everything except moving TempDB, which is moved with the ALTER DATABASE statement.

    One caveat with TempDB - make sure Model exists before you attempt to move it. If there is no Model database, TempDB can't be recreated in its new location.

  • Straight from the horse's mouth...

    http://support.microsoft.com/kb/224071/en-us

    Describes moving all of the system databases - tempdb, model, master, msdb, etc.

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

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