Changing the Outlet Number within an existing database:
- It is OK to be logged into the outlet that you are updating - when your running this routine, as it will force you back to the login window when the process has been completed.
- Have all users and web services 100% logged out of the outlet you are updating.
- This process will disable triggers one table at a time, as the table is updated.
- If your running this in a live environment where other outlets still may be using the database, perform this function when there is no access to the database from users, or web sales (i.e. after midnight). Due to the fact that triggers are being disabled on a table while the table is being updated.
- This routine is fairly fast but does depend on the hardware it's being run on. Running this process on a fully loaded server, a normal database may take anywhere from 30 - 60+ minutes to complete. On a large database (4 GB compressed backup), it may take anywhere from 10+ hours to complete.
- 160MB compressed backup took 25 minutes (June 2015)
- 455MB compressed backup took 60 minutes (June 2015)
Note: you will require remote access to the database via pgAdmin to execute 2 SQL commands to enable/disable a user access level (you will be prompted with the exact command during the process). Once just prior to running the process, and once again after the process has completed. The changing of the outlet number will still happen even without the enable/disable of the user access level, however it will just take longer to complete. The routine disables triggers from running on the updated table.
- Download the most recent "client" database
- Restore the downloaded "client" database
- Using the Developer Tool, Log into the "client" database as the Master User
- Reset Department Number (File >> Import/Export >> Outlet Settings >> Outlet Preferences)
- Enter in the FROM Outlet Number
- Enter in the TO Outlet Number
- Click "Reset Dept"