Dear Readers,
In this article we will see IgnoreDelete and IgnoreUpdate parameters in Oracle GoldenGate.
This article covers Oracle GoldenGate IgnoreDelete and IgnoreUpdate parameters for Oracle GoldenGate
- IGNOREUPDATES Parameter
- IGNOREDELETES Parameter
NOTE : The parameters used in this article could be used either in Extract,Data pump or Replicat parameter file.
As a task you should try to use these parameters in Extract and Pump file as well and then check stats.
Prerequisites
This Parameters we can use after configure GG setup & DML replication between two oracle databases.
Check below article for Oracle to Oracle GoldenGate Unidirectional Replication
GoldenGate: Oracle to Oracle GoldenGate Unidirectional Replication
Update replicat process by adding ignoreupdates & ignoredeletes Parameters
GG2:
On target side connect to GGSCI
1 2 3 4 5 6 7 8 9 |
[oracle@gg2 ~]$ cd /u01/app/oracle/product/ogg_trg [oracle@gg2 ogg_trg]$ ./ggsci Oracle GoldenGate Command Interpreter for Oracle Version 19.1.0.0.0 OGGCORE_19.1.0.0.0_PLATFORMS_190508.1447_FBO Linux, x64, 64bit (optimized), Oracle 12c on May 9 2019 06:21:59 Operating system character set identified as UTF-8. Copyright (C) 1995, 2019, Oracle and/or its affiliates. All rights reserved. GGSCI (gg2.orcl.com) 1> |
Check replicat process status
1 2 3 4 5 |
GGSCI (gg2.orcl.com) 1> info all Program Status Group Lag at Chkpt Time Since Chkpt MANAGER RUNNING REPLICAT RUNNING REPINT 00:00:00 00:00:10 |
Now make connection to database
1 2 3 |
GGSCI (gg2.orcl.com) 2> dblogin useridalias ggadmin_trg Successfully logged into database. |
Update the parameter file for the Replicat group ‘repint’ and add these two parameters :
IGNOREUPDATES
IGNOREDELETES
1 2 3 4 5 6 7 8 9 10 11 |
GGSCI (gg2.orcl.com as ggadmin@orcl) 3> edit param repint REPLICAT REPINT SETENV(ORACLE_SID='ORCL') SETENV(ORACLE_HOME='/oraeng/app/oracle/product/12.1.0') useridalias ggadmin_trg DBOPTIONS INTEGRATEDPARAMS(parallelism 4) ASSUMETARGETDEFS IGNOREUPDATES IGNOREDELETES MAP ajay.DEPT,target ajay.DEPT; |
Restart replicat process as
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 |
GGSCI (gg2.orcl.com as ggadmin@orcl) 4> stop repint Sending STOP request to REPLICAT REPINT ... Request processed. GGSCI (gg2.orcl.com as ggadmin@orcl) 5> info all Program Status Group Lag at Chkpt Time Since Chkpt MANAGER RUNNING REPLICAT STOPPED REPINT 00:00:00 00:00:06 GGSCI (gg2.orcl.com as ggadmin@orcl) 6> start repint Sending START request to MANAGER ... REPLICAT REPINT starting GGSCI (gg2.orcl.com as ggadmin@orcl) 8> info all Program Status Group Lag at Chkpt Time Since Chkpt MANAGER RUNNING REPLICAT RUNNING REPINT 00:00:00 00:00:20 |
Check repint process info
1 2 3 4 5 6 7 8 9 |
GGSCI (gg2.orcl.com as ggadmin@orcl) 9> info repint REPLICAT REPINT Last Started 2019-08-02 19:20 Status RUNNING INTEGRATED Checkpoint Lag 00:00:00 (updated 00:00:06 ago) Process ID 25516 Log Read Checkpoint File /u01/app/oracle/product/ogg_trg/dirdat/rt000000005 2019-08-01 19:59:09.526343 RBA 6913 |
To check information related to any parameter in GOLDENGATE use below command:
info param <paramanme>
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 |
GGSCI (gg2.orcl.com as ggadmin@orcl) 11> info param ignoreupdates param name : getupdates opposite param name : ignoreupdates description : Include update records. argument : boolean default : true options : component(s): EXTRACT REPLICAT mode(s) : all Extract modes all Replicat modes platform(s) : all platforms versions : database(s) : all supported databases (on the supported platforms). status : current mandatory : false dynamic : false relations : none GGSCI (gg2.orcl.com as ggadmin@orcl) 12> info param ignoredeletes param name : getdeletes opposite param name : ignoredeletes description : Include delete records. argument : boolean default : true options : component(s): EXTRACT REPLICAT mode(s) : all Extract modes all Replicat modes platform(s) : all platforms versions : database(s) : all supported databases (on the supported platforms). status : current mandatory : false dynamic : false relations : none |
On SOURCE GG1 :
Insert records on DEPT table
1 2 3 4 5 6 7 8 9 10 11 12 |
SQL> select * from dept; DEPTNO DNAME LOC ---------- -------------- ------------- 10 ACCOUNTING NEW YORK 20 RESEARCH DALLAS 30 SALES CHICAGO 40 OPERATIONS BOSTON 50 MARKETING USA SQL> insert into dept values(60,'ACCOUNTS','CANADA'); 1 row created. SQL> commit; Commit complete. |
On Target GG2 :
1 2 3 4 5 6 7 8 9 |
SQL> select * from dept; DEPTNO DNAME LOC ---------- -------------- ------------- 10 ACCOUNTING NEW YORK 20 RESEARCH DALLAS 30 SALES CHICAGO 40 OPERATIONS BOSTON 50 MARKETING USA 60 ACCOUNTS CANADA |
On Source GG1 :
Update a row into DEPT table
1 2 3 4 |
SQL> update dept set loc='IND' where deptno=60; 1 row updated. SQL> commit; Commit complete. |
Check stats of EXTINT process
Check stats of DPINT process
On Target GG1 :
Check stats of REPINT process(REPLICAT)
Replicat process ignored a update transaction. Now we will try with DELETE option
On SOURCE GG1 :
DELETE a record from DEPT table
1 2 3 4 |
SQL> delete from dept where deptno=60; 1 row deleted. SQL> commit; Commit complete. |
Check stats of EXTINT process
Check stats of DPINT process
On TARGET GG2:
Check stats of REPLICAT process
Replicat process ignored a update & DELETE transactions.
NOTE : The parameters used in this guide could be used either in Extract,Data pump or replicat parameter file. As a task you should try to use these parameters in Extract and Pump file as well and then check stats.
Thank you for giving your valuable time to read the above information. Please click here to subscribe for further updates
KTEXPERTS is always active on below social media platforms.
Facebook : https://www.facebook.com/ktexperts/
LinkedIn : https://www.linkedin.com/company/ktexperts/
Twitter : https://twitter.com/ktexpertsadmin
YouTube : https://www.youtube.com/c/ktexperts