Page 1 of 1

APT_CombinedOperatorController warning in DS parallel job

Posted: Wed Oct 04, 2006 11:32 am
by sri1111
I have a parallel job which inserts data from .DS file to a table in sql server. Due to unique key constraints I am not able to insert the data(some records are already existing in the table) I am using a copy stage.

This is the warning which I am getting:

APT_CombinedOperatorController,1: [Microsoft][ODBC SQL Server Driver][SQL Server]Violation of PRIMARY KEY constraint 'PK_Key'. Cannot insert duplicate key in object 'TabelX'.

I think I need to throw an exception in parallel job like FOR EXCEPTION tableschema.tabname but don;t know how to do that...

Any help is greatly appreciated.

Sri

Posted: Wed Oct 04, 2006 1:35 pm
by thumsup9
Sri,

What do you want to do here. Do you want to insert duplicate data into the target table. If not why dont you update and insert.

Posted: Thu Oct 05, 2006 12:26 am
by Kirtikumar
If you want to capture the rows where the rows are rejected or violating the contrains in table, then you can create the rejected link from the target database stage and handle the rejected rows.

Posted: Thu Oct 05, 2006 7:41 am
by kumar_s
But you cannot escape from getting warning related to this. Better do a conditional check prior to load.

Posted: Thu Oct 05, 2006 10:16 am
by samsuf2002
i used to get this error when i was inserting rows in SQL server the table already contains some rows i truncated the table and ran and it worked fine.

Posted: Thu Oct 05, 2006 4:29 pm
by sri1111
Thanks Guys....I am thinking of truncating the data and load into the table.