ITPub博客

首页 > 数据库 > Oracle > goldengate 的initial load 当目的表无pk或者ui时会产生重复记录

goldengate 的initial load 当目的表无pk或者ui时会产生重复记录

原创 Oracle 作者:msdnchina 时间:2011-09-28 22:35:58 0 删除 编辑
OGG can insert duplicate rows when there is no unique index primary key UI PK defined [ID 1350948.1]

Applies to:

Oracle GoldenGate - Version: 9.5_EA and later [Release: 9.5.0 and later ]
Information in this document applies to any platform.

Symptoms

Target table with no UI or PK has duplicate rows after initial load.
Replicat is (may be) using HANDLECOLLISIONS and KEYCOLS

Changes

An initial load.

Cause

It is possible to get duplicate rows because there is no key / index constraint to prevent it. Keycols will not help.

Solution

Replicat relies on the database to return a constraint error when a duplicate row is inserted. In cases where there is no UI or PK, no error is returned. HC will not help because there is no error. KEYCOLS is used as a retrieval mechanism, not an index on a write.
The fact that replicat treats the whole row as a key when there is no defined key is no help.
Replicat has no way of knowing it should not insert a duplicate row if there is no constraint.
User must define a key or UI.[@more@]

来自 “ ITPUB博客 ” ,链接:https://blog.itpub.net/161195/viewspace-1055385/ ,如需转载,请注明出处,否则将追究法律责任。

请登录后发表评论 登录
全部评论

注册时间:2008-07-30

  • 博文量
    498
  • 访问量
    1542056