DoorsNET Database Detach and Attach Rev-C
DoorsNET Database Detach and Attach Rev-C
This document explains how to detach a database (so that it can be copied to a backup
location and used in migrating a system to a different host PC/Server). A typical example
would be if you are migrating your system to an upgraded host or if you are upgrading
the Windows operating system.
This document guides you through the process of detaching and attaching a Doors.NET
SQL database using an SQL Express database engine. Keri recommends consulting an
IT administrator when administering databases installed in a full version of SQL Server.
This particular guide uses Windows 10 operating system and SQL Server 2012.
IMPORTANT NOTES
1. Two or more Doors.NET or DoorsNXT databases using the same controller MAC
addresses and TCP/IP addresses on the same network subnet will result in numerous
hardware communication issues.
2. Microsoft does not provide a downgrade path for SQL databases. This means you can-
not use 2008 or SQL 2012 files on a SQL 2005 database engine. You can, however use
SQL 2005 files on any other newer version of SQL Server.
3. You MUST ensure you have made a backup of your database before you attempt to
detach it. The quickest and easiest way to do this is via Tools >> Backup. The Live
Events grid will generate an event once the backup is complete.
The following procedure would typically be used to move the entire Doors.NET system
onto a different host workstation, or if the Windows operating system is being upgraded.
It uses SQL Express 2012 but the steps are almost identical as other SQL Express ver-
sions.
3. Please allow extra time for the program to configure itself and load if you are running it
for the first time.
4. A connection window will appear displaying the host name and the database instance
(default for Doors.NET is ECLIPSE).
5. Leave Authenticate at the default selection of Windows Authentication (you must
ensure you have full Administrative Rights to the PC). If Windows Authentication is dis-
abled you will need to consult an IT administrator.
6. Click on the Connect button.
9. From the Detach Database window check the Drop Connections option.
12. Two SQL database files will now be available (DHS_MAIN.mdf and DHS_MAIN_
log.mdf) that can be copied and moved to another PC that has been prepared with a
fresh install of Doors.Net and SQL Server/Server Express. These files must be copied to
same directory shown in the image below.
Note: For a 32-bit operating system the default database file path will be:
Program Files >> Microsoft SQL Server >> MSSQL.1 >> MSSQL >> Data
Note: The detach procedure is used if you have performed a fresh install of Doors.NET
using the default selections. You would detach the database that gets installed auto-
matically and then attach the backup database files (or converted database files for
upgrades from Doors32).
13. Keeping a copy of these two database files will also provide you with a full database
backup. But note: if the system has been periodically archiving event information you will
also need to keep copies of your archive database files.
3. A connection window will appear and will be displaying the host PC name, the
DoorsNET database instance of ECLIPSE and the Authentication Mode should be
4. Leave all settings at their default values and click the Connect button.
Note: At this point you should have already copied your back-up database files into the
default SQL file directory, as highlighted below:
7. The browse window will open automatically to the default SQL data folder.
11. In the lower left corner of the Attach database window, you can observe the green
progress bar so you know when the database is successfully attached.
12. Once complete the Doors.NET database will be listed under Databases in the left
pane of Studio Manager.
C:\Keri\DoorsNET).
NOTE: If the application server PC and the database PC are different, you should copy
this file to a thumb drive and then copy it somewhere onto the database PC (it doesn’t
matter where). This program must be run on the workstation that the database resides.
3. When the update database window appears you will see that Upgrade an existing
database is selected by default, so click the Next button.
- The server/PC name should be displayed along with the SQL instance of ECLIPSE. (1)
- The Authentication mode should be set to Windows Authentication. (2)
- The database you should select from the database list is DHS_MAIN. (3).
- Un-check Backup Target Database (unless you do specifically wish to create a backup
of the database). (4).
7. In a few moments you should see that the upgrade has completed.
The final step is to run the Gateway Wizard to associate the gateway windows service
with the attached database. Running the gateway Wizard is covered in a separate doc-
ument (P/N: 01565-002).
End of document.