Options for Creating the Checkpoint Table
The checkpoint table can reside in a schema of your choice. Use one that is dedicated to Oracle GoldenGate if possible.
More than one instance of Oracle GoldenGate (multiple installations) can use the same checkpoint table. Oracle GoldenGate keeps track of the checkpoints, even if Replicat group names are the same in different instances.
More than one checkpoint table can be used as needed. For example, you can use different ones for different Replicat groups.
You can install your checkpoint tables in these ways:
-
You can specify a default checkpoint table in the
GLOBALSfile. New Replicat groups created with theADD REPLICATcommand will use this table automatically, without requiring any special instructions. -
You can provide specific checkpoint table instructions when you create any given Replicat group with the
ADD REPLICATcommand:-
To use a specific checkpoint table for a group, use the
CHECKPOINTTABLEargument ofADD REPLICAT. This checkpoint table overrides any default specification in theGLOBALSfile. If using only one Replicat group, you can use this command and skip creating theGLOBALSfile altogether. -
To omit using a checkpoint table for a group, use the
NODBCHECKPOINTargument ofADD REPLICAT. Without a checkpoint table, Replicat still maintains checkpoints in a checkpoint file on disk, but you introduce the risk of data inconsistency.
-
However you implement the checkpoint table, you must create it in the target database prior to using the ADD REPLICAT command.
To Add a Checkpoint Table to the Target Database
The following steps, which create the checkpoint table through GGSCI, can be bypassed by running the chkpt_db_create.sql script instead, where db is an abbreviation of the database type. By using the script, you can specify custom storage or other attributes. Do not change the names or attributes of the columns in this table.
-
From the Oracle GoldenGate directory, run GGSCI and issue the
DBLOGINcommand to log into the database. The user issuing this command must haveCREATE TABLEpermissions. See Reference for Oracle GoldenGate for the correct syntax to use for your database. -
In GGSCI, issue the following command to add the checkpoint table to the database.
ADD CHECKPOINTTABLE
containerowner.tableWhere:
owner.tableis the owner and name of the table,containeris the name of a PDB if installing into an Oracle multitenant container database. The owner and name can be omitted if you are using this table as the default checkpoint table and this table is specified withCHECKPOINTTABLEin theGLOBALSfile. The name of this table must not exceed the maximum length permitted by the database for object names. The checkpoint table name cannot contain any special characters, such as quotes, backslash, pound sign, and so forth.
To Specify a Default Checkpoint Table in the GLOBALS File
This procedure specifies a global name for all checkpoint tables in the Oracle GoldenGate instance. You can override this name for any given Replicat group by specifying a different checkpoint table when you create the Replicat group.