Create a session and associate it with the mapping that you created to move data to an Amazon Redshift table. Change the connection to an Amazon Redshift connection, and define the session properties to write data to Amazon Redshift.
You can perform insert, update, delete, and upsert operations on an Amazon Redshift target.
In the source session properties, if you set
Update
as the value of the
Treat source as rows
property and select the
Update as Insert
option in the target session properties, the mapping runs successfully. However, the PowerCenter Integration Service rejects the data.
If the distribution key column in a target table contains null values and you configure a task with an
Update as Insert
operation for the same target table, the task might create duplicate rows. To avoid creating duplicate rows, you must perform one of the following tasks:
Replace the null value with a non-null value when you load data.
Do not configure the column as a distribution key if you expect null values in the distribution key column.
Remove the distribution key column from the target table temporarily when you load data. You can use the Pre-SQL and Post-SQL properties to remove and then add the distribution key column in the target table.