Skip to main content

Db2 for z/OS WAEvent fields

The output data type for an Db2 for z/OS external source is WAEvent. The fields are:

metadata:

  • ChangeTimestamp: timestamp of the change in Db2 (UTC)

  • LRSN: Db2 Log Record Sequence Number

  • OperationName: INSERT, UPDATE, or DELETE

  • ProcessingTimestamp: timestamp of processing in Db2 (UTC)

  • RBA: Db2 Relative Byte Address

  • TableName: the name of the table including its schema, for example, SCHEMA1.TABLE1

  • TxTimestamp: timestamp of the commit in Db2 (UTC)

  • URID: Db2 Unit of Recovery Identifier

To retrieve the values for these fields, use the META() function. See Parsing the fields of WAEvent for CDC readers.

data: an array of fields, numbered from 0, containing:

  • for an INSERT operation, the values that were inserted.

  • for an UPDATE, the values after the operation was completed

    BLOB, CLOB, and DBCLOB values are omitted if unchanged.

    Primary key updates result in two events: an INSERT with all the values, except BLOB, CLOB, DBCLOB, and XML values are omitted if unchanged, followed by a DELETE event with the previous primary key value.

  • for a DELETE, the value of the primary key and nulls for the other fields.

To retrieve the values for these fields, use SELECT ... (DATA[]). See Parsing the fields of WAEvent for CDC readers.

before: for UPDATE operations, contains the primary key value from before the update. When an update changes the primary key value, you may retrieve the previous value using the BEFORE() function.

dataPresenceBitMap, beforePresenceBitMap, and typeUUID are reserved and should be ignored.