User Tools

Site Tools


goldengate

GoldenGate

Parameter Files

10g Database

12c Database

Sequences

Known Issues

Exceptions

Alerting Script

SQL

Sequences Scheduled Job

set lines 120
col job_name format a20
col ACTUAL_START_DATE format a30
col run_duration format a30
select JOB_NAME, STATUS, to_char(ACTUAL_START_DATE,'DD-MON-YYYY HH24:MI') start_date, RUN_DURATION 
from dba_scheduler_job_run_details 
where job_name = 'SYNC_SEQUENCES_JOB'
order by 3;

Sequences Log Table

set lines 120
col sequence_name format a30
col sync_date format a40
select * from ggate.sync_sequences_log
order by sync_date;

Sequences Odd/Even Check

set lines 120
col sequence_name format a30
select * from ggate.mol_gg_sequences
order by owner;

select owner, sequence_name, valueint, valuepoc,
       case when mod(ValueInt,2) = mod(ValuePOC,2) then 'ERROR'
         else 'ODD EVEN SUCCESS'
       end Validation
from ggate.mol_gg_sequences
order by owner, sequence_name;

Synchronise Sequences Between Databases

SET PAGESIZE 0 LINESIZE 120 FEEDBACK OFF
spool /u07/goldengate/dirout/sequence_sync_output.sql
SELECT 'set echo on timing on' from dual;
SELECT 'conn ggate/ggate123' from dual;
SELECT 'exec mol_sequences.mol_sequence_sync(''' || SEQUENCE_OWNER || ''',''' || SEQUENCE_NAME || ''',100);'
FROM DBA_SEQUENCES
WHERE SEQUENCE_OWNER in ('MAILONLINE','RDRCOMMENTS','REGISTRATION','LEGAL','FBIAGENT')
AND   SEQUENCE_NAME not in ('HIBERNATE_SEQUENCE','HEALTHCHECK_SEQ','TN_TEST_SEQ')
ORDER BY 1;
spool off

Checkpoint Table

alter session set nls_date_format = 'DD-MON-YYYY HH24:MI:SS';
set linesize 100
col group_name format a12
col scn format a16
select GROUP_NAME, LOG_CSN as SCN, SEQNO, RBA, LAST_UPDATE_TS 
from GGATE.CHKPTAB;

Exceptions Table

SET LINESIZE 160
COL TABLE_NAME FORMAT A40
COL RECCSN FORMAT 999999999999
select to_char(EXCP_DATE,'DD-MON-YYYY HH24:MI:SS') EXCEPTION_DATE, 
       REP_NAME, TABLE_NAME, RECCSN, LOGRBA, LOGPOSITION, SRCROWID SOURCE_ROWID,
       ERRMSG FROM ggate.exceptions;

Production Installation

goldengate.txt · Last modified: 2021/12/06 11:30 by 127.0.0.1