Skip to content

Oracle Database target

TwinCommit applies changes to Oracle Database with array-bound MERGE statements, one batch per source transaction group. The checkpoint row is updated in the same Oracle transaction, so delivery is exactly-once.

Supported: Oracle 19c, 21c and 23ai · Autonomous Database · Amazon RDS for Oracle · Exadata.

target:
type: oracle
dsn: oracle://twincommit:${ORA_PASSWORD}@ora-scan.internal:1521/REPLPDB
schema: REPLICA
array_size: 1000
  • Inserts and updates become a single array MERGE ... USING (SELECT :1, :2 ... FROM dual) per table per batch.
  • Deletes are array-bound DELETE ... WHERE pk = :1.
  • The checkpoint in state_schema is updated, then the transaction commits. See exactly-once.
CREATE USER twincommit IDENTIFIED BY "********" QUOTA UNLIMITED ON users;
GRANT CREATE SESSION, CREATE TABLE TO twincommit;
GRANT SELECT, INSERT, UPDATE, DELETE ON replica.orders TO twincommit;
-- or, when TwinCommit owns the REPLICA schema:
GRANT UNLIMITED TABLESPACE TO twincommit;