You can create a single
DB2
database to store the Administration, Engine, and Fingerprint databases for a Datacap application.
Before you begin
You must create the
DB2
database and set up the appropriate permissions to the database. Review and complete the prerequisites for configuring Datacap databases.
About this task
You define the structure of the Datacap application databases by running SQL scripts for the Administration, Engine, and Fingerprint database schema.
You can run the SQL scripts for these Datacap application databases separately to create a separate
DB2
, SQL Server, or Oracle database for each of the application databases. Alternatively, you can run the SQL scripts together to create just one database that contains the Administration, Engine, and Fingerprint database schemas. This procedure creates a single
DB2
database user for all of the Datacap application databases.
Procedure
To create a single
DB2
user for the Datacap databases in your Datacap application:
-
Create a new user for the
DB2
database, for example,
new_db_user
. Grant DBADM privileges to new_db_user
.
Important: The user name new_db_user
is used as an example. Choose a more descriptive name such as CaptureInvoiceTM
or AcmeCapture
to identify the function of the particular Datacap application that this
DB2
database will be used for.
-
Start the
DB2
CLPPlus tool and log in as
new_db_user
.
-
Go to C:\Datacap\support\DBScript and find the following
DB2
scripts:
- DB2_Adm_Base.sql
- DB2_Eng_Base.sql
- DB2_FP_Base.sql
-
If this is not the first database that you are creating in this Datacap environment, you must modify the scripts to have unique
db_index
values to uniquely associate with the application:
IDs for the db_index
fields are hard-coded in the database creation scripts. If this is not the first database that you are creating in this Datacap environment, you must set a new numeric value in the db_index
column in the scripts (the adminfo
table in the Admin schema and the enginfo
table in the Engine schema) to uniquely identify the database with this Datacap application.
If you have one admin database per engine database for an application, you can use the same unique numeric ID in both databases. If you have multiple admin databases per engine database, specify different unique numeric IDs for each database, but use a numbering convention that simplifies the identification of those databases for an application.
Tip: When batches are created in the Engine schema, each queue table row contains column qu_admDB
. This value displays which admin database is associated with the batch.
-
Run the scripts.
-
Disconnect from the user account.
-
Copy the data from the source database by using the Datacap Application Copy Tool.
-
Point the Administration, Engine, and Fingerprint database schemas to the same location.
Tip: Because each of the Datacap databases is created in the same
DB2
database, the connection string for each of the Datacap databases will be the same per Datacap application.
-
Configure the Datacap application to use the database by using the database user name that you created in this task for that database.