Data and Transaction location

  • I installed SQL Server 2005 and forgot to change the location from C:\ drive to D:\ drive.

    How can I change the default location?

    It has some data and transaction files on default location, also need to move those to d:\ drive.

  • In SQL Server Management Studio, once you register and connect to the sql server, right click on the server name, click on Properties, then Database Settings.  There you will see the option to change the default location.  For the existing user databases, would it work if you detach and attach the physical files? 

    hth,

  • Acutally I did that but after I did that I went to check on D drive and no folder structer was created to store data (like ms sql data etc)?

    And on the original location there are different folder like Msql.1 , .2, .3,.4 for datafiles, logs, Analysis services etc. what will happen to all this folder once I change the database location and transaction or log files location?

    can I delete the original data structure.

  • If you wants new default location at D:\Program Files\Microsoft SQL Server\MSSQL you must manually create the folder first if it doesn't exist.  I do this way every time I install SQL 2000.  Hope it should work on SQL 2005.

    It seems that SQL uses each MSSQL.x for each additional service.  Only one folder is used for SQL databases, look like it is MSSQL.1.  The other folders are for Reporting, OLAP, etc.  If you change the default location, the system databases are still there unless you move them too.  However the MSSQL.x folder for SQL engine are used for log files, replication,etc.  so it is still there.

     

    hth,

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

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