ALLOWNONVALIDATEDKEYS
Valid For
GLOBALS
Description
Use ALLOWNONVALIDATEDKEYS
to allow Extract, Replicat, and GGSCI commands to use a non-validated primary key or an invalid key as a unique identifier. This parameter overrides the key selection criteria that is used by Oracle GoldenGate. When it is enabled, Oracle GoldenGate will use NON VALIDATED
and NOT VALID
primary keys as a unique identifier.
A key can become invalid as the result of an object reorganization or a number of other actions, but if you know the keys are valid, ALLOWNONVALIDATEDKEYS
saves the downtime of re-validating them, especially in a testing environment. However, when using ALLOWNONVALIDATEDKEYS
, whether in testing or in production, you accept the risk that the target data may not be maintained accurately through replication. If a key proves to be non-valid and the table on which it is defined contains more than one record with the same key value, Oracle GoldenGate might choose the wrong target row to update.
To enable ALLOWNONVALIDATEDKEYS
in a configuration where DDL replication is not active, stop all processes, add ALLOWNONVALIDATEDKEYS
to the GLOBALS
parameter file, and then restart the processes. To disable ALLOWNONVALIDATEDKEYS
again, remove it from the GLOBALS
file and then restart the processes.
To enable ALLOWNONVALIDATEDKEYS
functionality in a configuration where DDL support is active, take the following steps.
-
Add the
ALLOWNONVALIDATEDKEYS
parameter to theGLOBALS
parameter file. -
Update the
GGS_SETUP
table in the DDL schema by using the following SQL.UPDATE owner.GGS_SETUP SET value='1' WHERE property='ALLOWNONVALIDATEDKEYS'; COMMIT;
-
Restart all Oracle GoldenGate processes including Manager. From this point on, Oracle GoldenGate selects non-validated or non-valid primary keys as a unique identifier.
To disable ALLOWNONVALIDATEDKEYS
functionality when DDL support is active, take the following steps.
-
Remove
ALLOWNONVALIDATEDKEYS
from theGLOBALS
parameter file. -
Update the record that you added to the
GGS_SETUP
table to0
.UPDATE owner.GGS_SETUP SET value='0' WHERE property='ALLOWNONVALIDATEDKEYS'; COMMIT;
Restart all of the Oracle GoldenGate processes.
Default
None (Disabled)
Syntax
ALLOWNONVALIDATEDKEYS