Lookup warning-Ignoring duplicate entry at table record

A forum for discussing DataStage<sup>®</sup> basics. If you're not sure where your question goes, start here.

Moderators: chulett, rschirm, roy

Post Reply
aluthra48
Participant
Posts: 66
Joined: Thu Mar 05, 2009 9:59 am

Lookup warning-Ignoring duplicate entry at table record

Post by aluthra48 »

Hello,

I have a following error in one of my jobs:
LKP_DIAGNOSIS_BRIDGE,0: Ignoring duplicate entry at table record 720; no further warnings will be issued for this table

I know what the error means, and can fix it, but the question I have is:

If there are several rows returned from a reference table with the same key value, is the lookup value at least picked up from one of those several rows, while of course ignoring the other rows in the set?

Thanks
ArndW
Participant
Posts: 16318
Joined: Tue Nov 16, 2004 9:08 am
Location: Germany
Contact:

Post by ArndW »

The warning message means that DataStage detected a duplicate key while building up the lookup table and only stored the first key and it's corresponding data values. When doing the lookup with actual data, only that value is in the table and therefore only that value is returned.
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

Unless, of course, you've selected that reference link as "allow duplicates".
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
aluthra48
Participant
Posts: 66
Joined: Thu Mar 05, 2009 9:59 am

Post by aluthra48 »

Thanks for the response.

As I mentioned, I know what the message means, and what I need to do to fix it. The question was, in case there are more than one row returned for lookup, as it did here, does DS ignore the lookup value, or it looks up the value from the first available reference row, and ignores the rest of the rows?
Of course, I can set up a simple test to verify.
aluthra48
Participant
Posts: 66
Joined: Thu Mar 05, 2009 9:59 am

Post by aluthra48 »

I just conducted a test. If there are 2 reference rows returned with the same key value, the value of the column looked up is the value from the 1st row returned, and value from the 2nd row is ignored.
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

Which is exactly what Arnd told you.
-craig

"You can never have too many knives" -- Logan Nine Fingers
wittyme
Premium Member
Premium Member
Posts: 151
Joined: Tue Sep 15, 2009 2:03 pm
Location: Chicago

Post by wittyme »

Where can we find the allow duplicates in the lookup stage. Sorry I couldn't see that
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

I assume, because the thread is marked as Resolved, that you found it (a drop-down list on the Constraints page).
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Post Reply