New messages can be written directly to PageGate's industry standard MS Access compatible database. This is a common integration method for 3rd party applications.
The following instructions are for: PageGate v8.0 | Windows 2008 R2 (64-bit) | MS SQL Server 2014 | MS Access 2010 (64-bit)
PageGate version 8.0 should be installed and running 'normally' before taking these steps. Make sure PageGate is setup to run as a service.
Overview
Direct Database WriteNew messages can be written directly to PageGate's industry standard MS Access compatible database.
Common Integration MethodA popular integration method for 3rd party applications that can write to an MS Access database.
Standard FormatPageGate uses an industry standard MS Access compatible database format for broad compatibility.
Procedure
1Stop PageGate
- Be sure to stop ALL of the PageGate programs from running (i.e. PG Server, PG Admin, PG Monitor, PG GUI Clients, etc.)
2Backup
- If you have existing data in your PageGate program, be sure to make a backup of your PageGate database. The database file is named pagegate.mdb and is found in the
c:\PageGateData\Database\ folder by default.
3Create a user for the PageGate services and give it rights to the SQL server
- Create a new user named something like pguser. The new user must have local administrator rights.
- Run the Microsoft SQL Server Management Studio.
- Expand the 'Security' object.
- Right-click on 'Logins' and choose 'New Login'.
- Select the 'General' object on the left.
- Add the new pguser account to the 'Login name' field (use the Search button to get the full user name).
- Select the 'Server Roles' object on the left.
- Check the 'ssadmin' box.
- Hit 'OK'.
- Close out of the Microsoft SQL Server Management Studio.
4Update the PageGate services to use the new user account
- Start the Windows Service Manager (Start → Administrative Tools → Services).
- For each PageGate service listed (they all start with the letter 'p'), do the following:
- Right-click on the service name and choose 'Properties' from the menu.
- Select the 'Log On' tab.
- Select the 'This account' option.
- Enter (or use the 'Browse' button) the pguser account and password.
- Hit 'OK' — the first time you do this you should get a popup saying the user has been granted the Log On As A Service right.
- Close out of the Service Manager.
5Log in with the newly created user account
- Log out as the current user.
- Log back in using the new pguser account.
6Import PageGate Database Structure and Data into SQL server
- Run the SQL Server 2014 Management Studio.
- Enter necessary information to connect to your SQL server.
- Go to 'Tools' → 'Options' → 'Designers' and make sure 'Prevent saving changes that require table re-creation' is not checked.
- Right-click on 'Databases' and choose 'New Database'.
- Name the database pgsqldatabase or something similar and hit 'OK'.
- Expand the 'Databases' object to show the newly created database.
- Right-click on the new database object and go to 'Tasks' → 'Import Data', this will start the Import Wizard.
- Hit 'Next' to get past the wizard's welcome screen.
- For 'Data source' choose 'Microsoft Access (Microsoft Jet Database Engine)', and hit 'Next'.
- Use the 'Browse' button to find the PageGate database file (by default:
c:\pagegatedata\database\pagegate.mdb).
- Unless you have setup a password on the PageGate database file (not typical), leave the 'User name' and 'Password' fields blank.
- Hit 'Next'. For 'Destination' choose 'Microsoft OLE DB Provider for SQL Server'.
- Leave all the default values, unless you need to use SQL Server Authentication.
- Hit 'Next'. Choose 'Copy data from one or more tables or views' and hit 'Next'.
- Select all the tables as source tables and hit 'Next'.
- Leave 'Run immediately' checked and hit 'Next', then hit 'Finish'.
- After all the tables are finished being imported successfully, hit 'Close'.
7Modify Database Structure
Some changes to the new SQL database need to be made after the import.
- While still in SQL Server 2014 Management Studio expand the 'Tables' object under the new PageGate database object.
- Right-click on the dbo.lookup table and choose 'Design'. Select the 'id' field. Under 'Column Properties', expand 'Identity Specification', change 'Is Identity' to 'yes'. Right-click on 'id' and choose 'Set Primary Key'. Close and save.
- Right-click on the dbo.messages table and choose 'Design'. Select the 'message_id' field. Change 'Is Identity' to 'yes'. Set as Primary Key. Close and save.
- For all remaining tables: right-click, choose 'Design', add a new column named record_id with data type int, set 'Is Identity' to 'yes', set as Primary Key, close and save.
- Close out of the SQL Server 2014 Management Studio.
8Create a DSN (data source name) for the new PageGate SQL database
- Run
c:\windows\syswow64\odbcad32.exe (the 32-bit ODBC Data Source Administrator).
- Select the 'User DSN' tab.
- Hit 'Add'. Select the 'SQL Server' driver from the list and hit 'Finish'.
- Use pgdatasource for both the 'Name' and 'Description' fields.
- Enter the SQL server in the 'Server' field and hit 'Next'.
- Make any necessary changes to the authentication settings and hit 'Next'.
- Check 'Change the default database to:' and select the PageGate database (pgsqldatabase) from the list.
- Hit 'Next', leave defaults on the next screen, and hit 'Finish'. Test the data source if desired, then hit 'OK'.
9Create linked tables in MS Access
- Run MS Access 2010 and open the PageGate database (default:
c:\pagegatedata\database\pagegate.mdb).
- Choose 'External Data' → 'ODBC Database' from the toolbar.
- Choose 'Link to the data source by creating a linked table' and hit 'OK'.
- Select the 'Machine Data Source' tab, choose pgdatasource from the list and hit 'OK'.
- Select all the dbo.* tables (there should be 15 of them). Check 'Save password' and hit 'OK'. Hit 'Save Password' each time prompted.
- Rename all the existing pagegate tables (the ones without a dbo_ prefix), e.g. ahm can be renamed to original_ahm.
- Remove the dbo_ prefix from all the SQL tables so their names match the original PageGate table names.
- Select 'Linked Table Manager' from the toolbar. Hit 'Select All', then 'OK'. After relinking completes, quit MS Access.
10Try it out
- Start PG Monitor.
- Start PG Admin.
- Start the PageGate server.
Need help with database integration?
Our team can assist with custom integration into PageGate's database.