views:

2312

answers:

3

Using MS SQL Server Management Studio 2005 - To Restore a Database:

  • Restore Database
  • (*) From Device:
  • Click "..." Button
  • Backup media: File
  • Click "Add" Button
  • Popup Window: "Locate Backup File"

That window Defaults to C:\Program Files\Microsoft SQL Server\MSSQL.1\Backup

How do I configure MS SQL Server Management Studio to look in D:\data\databases\
instead of looking in C:\Program Files\Microsoft SQL Server\MSSQL.1\Backup ?

+5  A: 

In the registry, edit the HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Microsoft SQL Server\MSSQL.1\MSSQLServer\BackupDirectory value to point to d:\data\databases

henriksen
I had been curious if their was a way to configure it from within the gui, but these registry changes will do just as well.
KyleLanser
+3  A: 

It's stored in the registry.

On my computer, it's at...

HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Microsoft\Microsoft SQL Server\MSSQL.1\MSSQLServer

There is a registry key named BackupDirectory

I suspect the registry key will be in a different location for you (I have 64 bit vista). I did a search in my registry for 'MSSQL.1\Backup' to find it.

G Mastros
+1  A: 

For convenience, here's a reg file entry to do this:

Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Microsoft SQL Server\MSSQL.1\MSSQLServer]
"BackupDirectory"="D:\\data\\databases\\"
jeremcc