Db2 for LUW CDC Connector > Db2 for LUW CDC administration > Handling changes to extraction maps

Handling changes to extraction maps

If you make table definition changes that affect the columns from which change data is captured, perform this procedure to enable PowerExchange to switch to the updated table definition, while preserving access to previously captured data.
If you add or drop columns in a Db2 for LUW source table, you must create a new capture registration. PowerExchange generates an associated extraction map by default. Use the generated extraction map instead of creating a user-defined extraction map. PowerExchange on the Db2 for LUW CDC Connector system retrieves information from the newly generated extraction map.
Note: You do not need to perform these steps if you selectively capture change data for a subset of columns, and none of the selected columns are affected by the table definition changes.
    1. Stop all transactions, applications, and other activity that update the source table.
    2. Verify that any change data that was captured under the current table definition has completed Db2 for Linux, UNIX, and Windows CDC Connector extraction processing. Then stop all mapping tasks that extract change data for the table.
    3. Shut down the PowerExchange Logger for Linux, UNIX, and Windows.
    4. In the PowerExchange Navigator, delete the original capture registration and extraction map.
    5. Use DDL to make the changes to the table.
    6. In the PowerExchange Navigator, create a new capture registration that reflects the metadata changes and set its status to Active. A corresponding extraction map is generated.
    Tip: Use the original registration name so that you do not need to the edit the map name that is used by the workflows that contain the changed source table.
    7. Warm start the PowerExchange Logger for Linux, UNIX, and Windows.
    The PowerExchange Logger begins capturing changes based on the new capture registration.
    8. If necessary, change the target table definition to reflect the source table metadata changes.
    9. In Data Integration, for each mapping that includes the source table, perform the following steps:
    1. a. Select the Source transformation. Under Source Properties, either click the Synchronize button on the Fields tab or select the table again in the Object field on the Source tab. Either action causes the PWX CDC Metadata Adapter to retrieve the updated extraction-map metadata.
    2. b. If you changed the target table, select the Target transformation. Under Target Properties, click the Synchronize button on the Target Fields tab or select the table again in the Object field on the Target tab.
    3. c. Edit the field mapping to reflect the added or removed columns.
    10. If necessary, rematerialize the target tables.
    11. In the mapping task, set a time-based restart point that coincides with the time of target rematerialization or let the mapping task restart from the last checkpoint that was recorded in the state table on the target.
    12. Resume change activity on the source table.
    13. Start the mapping task again.