Table of Contents

Search

  1. Preface
  2. Part 1: Introduction
  3. Part 2: PowerExchange Client for PowerCenter (PWXPC)
  4. Part 3: PowerExchange ODBC
  5. Appendix A: PowerExchange Interfaces for PowerCenter Tips
  6. Appendix B: Datatypes and Code Pages
  7. Appendix C: PowerExchange Interfaces for PowerCenter Troubleshooting

PowerExchange Interfaces for PowerCenter

PowerExchange Interfaces for PowerCenter

Treating Source Rows as Updates

Treating Source Rows as Updates

PowerExchange extraction maps include the DTL_CAPXACTION column, which indicates whether the change is an insert, update, or delete. When you import an extraction map in Designer, PWXPC includes this column in the source definition. The PowerCenter Integration Service uses the column to determine which action PowerCenter applies to the row when the row reaches the target.
You might need to configure a session to treat each source row as an update, regardless of the value of the DTL_CAPXACTION column. For example, suppose the change stream includes multiple row inserts that have the same value for a non-key field in the source table. If this field is the key field of the target table, an attempt to insert the rows into the target table results in a primary key constraint violation.
To configure a session to move each source row to the target as an update, complete the following steps:
  1. In the Task Developer, double-click the session to edit it.
  2. Click the
    Properties
    tab.
  3. For the
    Treat Source Rows As
    attribute, select
    Data driven
    .
  4. In the Mapping Designer, add an Update Strategy transformation to the mapping.
  5. Open the Update Strategy transformation.
  6. Click the
    Properties
    tab.
  7. Click the button next to the
    Update Strategy Expression
    field.
  8. Enter an update strategy expression to always mark rows as updates.
  9. Validate the expression and click
    OK
    .
  10. Click
    OK
    .
  11. Connect the ports in the Update Strategy transformation to another transformation or a target instance.
When you run the session, PowerCenter moves each source row to the target as an update if possible. If a row with a matching primary key value is not present in the target system, PowerCenter inserts the row.
For CDC data sources, if you select
Insert
,
Update
, or
Delete
for the
Treat Source Rows As
property, the Integration Service ignores the selection and uses the action that is indicated in the DTL_CAPXACTION column.

0 COMMENTS

We’d like to hear from you!