因为在extract參数文件里使用了where语句,而where后面的的条件列又不是主键,没有为update、delete操作记录日志,因此会报1008错误。

Applies to:

Oracle GoldenGate - Version 10.0.0.1 and later

Information in this document applies to any platform.

Symptoms

1. I am using filter or where clause in extract parameter file and the column is not a part of primary or unique key



2.Update and delete operations are not captured and following warning message is logged to discard file and ggserr.log file

Cause

By default, When trandata is added, for a Oracle database supplemental logging is enabled only for primary key columns. If a column other than primary key column is used in FILTER or WHERE clause, then that column needs to be logged for update and delete operations.



By default, In OGG deletes are COMPRESSDELETES, it causes Extract to write only the primary key value to the trail, for delete operations.                                                                                             



So the column will not be logged for update or delete operations, which will make the extract discard the update/delete operations as bad records to discard file, due to missing field
For Non-Oracle databases, updates are compressed updates, it logs only key column used by extract to trail.

Solution

For Oracle database

1. Enter into ggsci



2. Stop the extract



3. Delete trandata <schema>.<table_name>



4. Add trandata <schema>.<table_name>, nokey, cols (col1, col2)

where col1 is the primary key column and col2 is the column included in filter clause.



5. Add the following parameter to extract parameter file. By default, it is compressed deletes.



NOCOMPRESSDELETES



6. Restart the extract

For Non-Oracle database (DB2 LUW,  DB2 z/OS, Teradata version 12 or later,  SQL Server, Sybase)

1. Enter into ggsci

2. Stop the extract

ggsci>stop extract <extract-name>

3. Add the following parameter to extract parameter file

NOCOMPRESSUPDATES

NOCOMPRESSDELETES

4. Restart the extract and retest the issue

Note :Upcoming updates and delete operations will work fine. The records captured so far does not have the value logged in archive log file for the column used in FILTER clause.
Also if the filter clause is used in replicat parameter file but  not in extract. The replicat may ignore those records without any warning or error messages. Solution is same as above 

OGG-01008 Extract displays Discarding bad record (discard recs=1) when using filter or where clause的更多相关文章

  1. ogg:Extract 进程遇长事务执行 Forcestop 引发的惨案

    http://www.linuxidc.com/Linux/2015-04/115777.htm SQL> select t.addr,t.START_DATE from v$transacti ...

  2. 【OGG】OGG基础知识整理

    [OGG]OGG基础知识整理 一.GoldenGate介绍 GoldenGate软件是一种基于日志的结构化数据复制软件.GoldenGate 能够实现大量交易数据的实时捕捉.变换和投递,实现源数据库与 ...

  3. OGG ERRORS 总结

    OGG ERRORS 总结 */--> OGG ERRORS 总结 Table of Contents 1. libnnz11.so 2. 00446 2.1. missing filename ...

  4. oracle ogg 单实例双向复制搭建(oracle-oracle)--Oracle GoldenGate

    oracle ogg 单实例双向复制搭建(oracle-oracle)--Oracle GoldenGate --继昨天的测试,这一篇实施单实例双向复制(完全重新搭建) --环境不变 db1,db2( ...

  5. ogg跳过某个RBA

    1.从库复制进程报如下错误 *************************************************************************              ...

  6. OGG学习笔记01-基础概述

    OGG学习笔记01-基础概述 OGG(Oracle Golden Gate),最近几年在数据同步.容灾领域特别火,甚至比Oracle自己的原生产品DataGuard还要风光,主要是因为其跨平台.跨数据 ...

  7. OGG学习笔记02-单向复制配置实例

    OGG学习笔记02-单向复制配置实例 实验环境: 源端:192.168.1.30,Oracle 10.2.0.5 单实例 目标端:192.168.1.31,Oracle 10.2.0.5 单实例 1. ...

  8. Oracle中对XMLType的简单操作(extract、extractvalue...)

    Oracle中对XMLType的简单操作(extract.extractvalue...)    1.下面先创建一个名未test.xml的配置文件. <?xml version="1. ...

  9. MySQL data sync to Oracle with OGG(Remote Delivery)

    MySQL to Oracle with OGG 1. Install MySQL: yum install mysql-community-server [root@localhost ~]#  y ...

随机推荐

  1. 在gfs2中关闭selinux

    在构建iSCSI存储集群时,请勿在gfs2中使用selinux

  2. C++中的常对象和常对象成员

    常对象 常对象必须在定义对象时就指定对象为常对象. 常对象中的数据成员为常变量且必须要有初始值,如 Time const t1(12,34,36); //定义t1为常对象 这样的话,在所有的场合中,对 ...

  3. Swift - 开关按钮(UISwitch)的用法

    下面演示如何创建开关,以及监听它值的改变,代码如下: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 class ViewController: UIV ...

  4. Emotion英语学习

    英语学习断断续续也快两年了,以前也蜻蜓点水地写过几篇总结,但是因为思考的少,只能得到一些表面的收获.从今年三月初到现在,口语阶段已经有三个月,感触较多,所以写这篇博客对这段时间英语学习的一个整体总结. ...

  5. [Android学习笔记]Android中多线程开发的一些概念

    线程安全: 在多线程的情况下,不会因为线程之间的操作而导致数据错误. 线程同步: 同一个资源,可能在同一时间被多个线程操作,这样会导致数据错误.这是一个现象,也是一个问题,而研究如何解决此类问题的相关 ...

  6. RAC 备份到本地不同设备

  7. ORALCE 之LRU链与脏LRU链【转载】

    今天是2013-09-09,时别n久的一篇经典文章,有被我在google发现了,再次转载一下.学习一下. 一.LRU链: 任何缓存的大小都是有限制的,并且总不如被缓存的数据多.就像Buffer cac ...

  8. Android中使用JNI获得APK签名的哈希值

    原地址:http://blog.csdn.net/i5suoi/article/details/19036975 最近在研究android应用中的安全问题,貌似只有将核心代码写到JNI底层才是最安全的 ...

  9. HDU4719-Oh My Holy FFF(DP线段树优化)

    Oh My Holy FFF Time Limit: 5000/2500 MS (Java/Others)    Memory Limit: 65535/65535 K (Java/Others) T ...

  10. poj3177(边双连通分量+缩点)

    传送门:Redundant Paths 题意:有n个牧场,Bessie 要从一个牧场到另一个牧场,要求至少要有2条独立的路可以走.现已有m条路,求至少要新建多少条路,使得任何两个牧场之间至少有两条独立 ...