SCD stage gives Primary key violation Warnings

Post questions here relative to DataStage Enterprise/PX Edition for such areas as Parallel job design, Parallel datasets, BuildOps, Wrappers, etc.

Moderators: chulett, rschirm, roy

Post Reply
changming
Participant
Posts: 68
Joined: Wed Oct 13, 2004 3:35 am

SCD stage gives Primary key violation Warnings

Post by changming »

Hi DS Guru
I have job which read data source and insrt or update dimension using SCD stage. One wired thing is it runs ok until I add new column in target table (add same column in refrence table too). becuase of this type 1 column, I got below warining.
One or more values in the INSERT statement, UPDATE statement, or foreign key update caused by a DELETE statement are not valid because the primary key, unique constraint or unique index identified by "1" constrains table "EDW.ENTITY" from having duplicate values for the index key

the only constraint is SK, which should be use as key to update or insert. Any idea why this happened?
thanks
changming
Participant
Posts: 68
Joined: Wed Oct 13, 2004 3:35 am

Re: SCD stage gives Primary key violation Warnings

Post by changming »

I thnk there must be some new line char which cant be read and load correctly. I used substring function to only leave 75 varchar and job runs ok. now I know how the log does not always give meaningful information.
Post Reply