SETIMAGE - connect_cdc_sqdata - Latest

Connect CDC (SQData) Apply engine

Product type
Software
Portfolio
Integrate
Product family
Connect
Product
Connect > Connect CDC (SQData)
Version
Latest
Language
English
Product name
Connect CDC (SQData)
Title
Connect CDC (SQData) Apply engine
Copyright
2024
First publish date
2000
Last edition
2024-07-30
Last publish date
2024-07-30T20:19:56.898694

The SETIMAGE function select the CDC Image (BEFORE or AFTER) to be used as the source (or target) datastore which makes it possible to use the same PROC for both images. The SETIMAGE function returns FALSE if you specify BEFORE and the CDC record is not an update (change).

Category

Specialized

Syntax

SETIMAGE (['BEFORE'] | ['AFTER'])

Parameter and Description

Parameter Description
'BEFORE' | 'AFTER' Specifies that subsequent operations will reference either the 'BEFORE' or 'AFTER' values of items in the source CDC record.

Example

Map the contents of both the BEFORE and AFTER values of a CDC Update record to separate Before and After columns in a target DESCRIPTION.
SETIMAGE('BEFORE')
CALLPROC PROCESS DEPT_REORG

SETIMAGE('AFTER')
CALLPROC PROCESS DEPT_REORG
CREATE PROC DEPT_REORG AS SELECT
{
   T_DEPT.DEPTNO     = DEPT.DEPTNO
   T_DEPT.DEPTNAME   = DEPT.DEPTNAME
   ...
   APPLY (Target, T_DEPT)
}
FROM CDCIN;
Note: Function @BEFORE simplifies referencing individual BEFORE values of specific fields.