Skip to Main Content

GoldenGate

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

How to handle deleted record when recreated with same PK in GG replication?

Sai Rajendra Vadakattu-OracleOct 5 2016 — edited Oct 5 2016

Hi,

One on our customer is using GG to replicate data and he is facing ORA-00001 : Unique Constraint violated error while replicating data in target.

Find the details below:

1. customer inserted a record in source system -> GG replicated this record as insert by setting flag = 'I' (extra column on target)

2. customer deleted above record in source system -> GG replicated this record as update by setting flag = 'D' ..  on target we have soft delete and record in not deleted exactly instead it just set flag as D but PK is same as source.

3. customer inserted new record in source system with same PK similar to deleted record in step2 -> Now GG replication is failing with 'ORA-00001 : Unique Constraint violated error '

Any solution/suggestions on this issue? Does GG reads data in target table before creating insert or update stmt?

Thanks in Advance.

Regards,

Rajendra

Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Nov 2 2016
Added on Oct 5 2016
1 comment
173 views