Using journal control fields for auditing replication activities

Journal control fields are a set of fields that contain different information about a journal entry associated with a source table change. Journal control fields can be assigned to target columns, as journal entry information is replicated with source table data. In Management Console, journal control fields are denoted with an ampersand (&) before the name of the field

Journal control fields provide information about the log entry on the source system. When a change is made on the source system, the database records the change in a log entry that contains the changed data plus extra information about what type of change was made, who made the change, and when the change was made. When a relevant log entry triggers a replication event to the target system, CDC Replication replicates the changed data along with the extra log entry information to the target system. CDC Replication makes the extra log entry information available through journal control fields.

CDC Replication provides many journal control fields that contain log entries from your source systems. You can map journal control fields to columns on the target system. CDC Replication replicates the log information from the source system and applies this information to the mapped columns on your target system. For example, you may want to maintain when the last replicated change was applied to each row in a table on the source system. To capture this information for each row in a table on the target system, you can add a column to the table and map that column to the appropriate journal control field. You can also include journal control fields in row selection and derived expressions.

Before using a journal control field, you should consider the following issues:

  • Depending on the type of platform you have installed CDC Replication and the replication method (mirror or refresh), some journal control fields may or may not be supported.
  • If you have installed the CDC Replication Engine for Db2® for z/OS® and you want to build an expression with &MEMBER, then you need to enclose this journal control field in single quotation marks.
  • CDC Replication does not support the mapping of journal control fields to LOB columns in a target table.