Change Location of Express Maintenance Database Files
Occasionally, users need to change the location of the Express Maintenance database files. Usually, it is desirable to locate the database files on a different drive with more free space.
You should first know that the database engine is the MSDE which is a scaled down version of the Microsoft SQL Server. It is a wonderful database engine but does not function like a regular flat database. You cannot move the file around at will with copy and paste, etc. You can get more details on the database engine here: What database engine does the software use?
The actual database files are ExpressMaintenance_Data.mdf and ExpressMaintenance_Log.ldf. They reside in the \\MSSQL7\\Data folder. The same files reside in the \\ExpressTech folder but they were just used as templates to create the acutal database.
In order to relocate the data files, you must stop the database engine, drop the database, copy the files, restart the database engine and attach the database files. Assuming you do not own your own copy of Microsoft SQL Server, contact the sales team for details on how to download and install Express SQL.
To move the Express Maintenance database, follow these steps at the server:
- Use Express Maintenance to make a backup of the data before beginning. This is done under Administration / Backup & Restore.
- Exit all sessions of Express Maintenance, Express Request and any other programs using the MSDE / SQL Database Engine.
- Click on Start / Program Files / MSDE and open the Service Manager.
- In the Service Manager, click on the Stop button to Stop the database engine.
- Using the Windows explorer, go to the MSSQL7\\Data folder and COPY ExpressMaintenance_Data.mdf and ExpressMaintenance_Log.ldf files to a temporary drive and folder or the desired drive and folder.
- In the Service Manager, click on the Start button to Start the database engine.
- Run Express SQL and connect to the SQL server. You must connect with the “sa” user login account and you must connect to the “master” database. The “sa” password is likely blank (no password).
- Right click on the database and select Delete database
- Click on the Data Connection tab button to return to the main page of the Express SQL.
- Right click on the database list and left click on Create New Database button to activate the wizard.
- Select the ExpressMaintenance_Data.mdf data file and the ExpressMaintenance_Log.ldf log file from the folder used in step 5 above. This will be the data files used to create the new database. Click Next.
- Enter / select the drive and folder where the new database files are to reside. Click Next.
- Enter the new database name which should be Express Maintenance. Click Create button to create the new database
- The new database should now exist. You can return to the Connection tab of Express SQL and select the Express Maintenance database and use the Explore Data to see the tables, data, etc. Exit Express SQL when ready.
- Run Express Maintenance from the server to insure that everything is working properly. You will want check the Connection.ini file if needed before setting up shortcuts.