DSXchange: DataStage and IBM Websphere Data Integration Forum
View next topic
View previous topic
Add To Favorites
This topic has been marked "Resolved."
Author Message
nikita.bandekar
Participant



Joined: 06 May 2019
Posts: 6

Points: 54

Post Posted: Sun Oct 13, 2019 7:13 pm Reply with quote    Back to top    

DataStage® Release: 11x
Job Type: Parallel
OS: Windows
Additional info: Working on Remote Desktop
I have a lookup stage which has input records with null values. Basically I want the lookup stage to Reject records when there are unmatched records but continue when there are null values on the key.
My input columns and receiving columns are nullable and Lookup Failure is set to 'Reject'

Not sure where i am going wrong.
Thanks in advance.

Regards,
Nikita

_________________
nikita bandekar
chulett

Premium Poster


since January 2006

Group memberships:
Premium Members, Inner Circle, Server to Parallel Transition Group

Joined: 12 Nov 2002
Posts: 43035
Location: Denver, CO
Points: 222143

Post Posted: Mon Oct 14, 2019 6:20 am Reply with quote    Back to top    

Take this with a grain of salt as it's been a long time but I think you'll need to stop rejecting any records by the Lookup stage. After the lookup, query the results and "reject" them yourself by looking for NULL values in the returned keys and compare that to the submitted keys. Decide based on the source values.

_________________
-craig

I've all my wisdom teeth, Two up top, two beneath
And yet I'll recognize my mouth says things that aren't so wise
Rate this response:  
Not yet rated
ray.wurlod

Premium Poster
Participant

Group memberships:
Premium Members, Inner Circle, Australia Usergroup, Server to Parallel Transition Group

Joined: 23 Oct 2002
Posts: 54541
Location: Sydney, Australia
Points: 295742

Post Posted: Mon Oct 14, 2019 11:16 pm Reply with quote    Back to top    

Use a conditional lookup with an IsNotNull() condition on the lookup key in the stream input, and mark the Condition Failed rule Continue .

_________________
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Rate this response:  
Not yet rated
chulett

Premium Poster


since January 2006

Group memberships:
Premium Members, Inner Circle, Server to Parallel Transition Group

Joined: 12 Nov 2002
Posts: 43035
Location: Denver, CO
Points: 222143

Post Posted: Tue Oct 15, 2019 6:23 am Reply with quote    Back to top    

A "conditional lookup"? All that comes to mind is something from years ago, a specific stage which was only available in the mainframe version of the product. Has that been merged into the core product?

Okay, a quick search seems to confirm my memory. It is only listed under the Mainframe Job Stages topic online and for some reason only up through the 9.x version of the product. Odd that trying to switch the version to 11.x give me an error about no matching topic. Confused

Still seems to me that you will need to provide the conditional logic...

_________________
-craig

I've all my wisdom teeth, Two up top, two beneath
And yet I'll recognize my mouth says things that aren't so wise
Rate this response:  
Not yet rated
nikita.bandekar
Participant



Joined: 06 May 2019
Posts: 6

Points: 54

Post Posted: Tue Oct 15, 2019 5:59 pm Reply with quote    Back to top    

ray.wurlod wrote:
Use a conditional lookup with an IsNotNull() condition on the lookup key in the stream input, and mark the Condition Failed rule Continue . ...


This worked like a charm!! Very Happy
Thank you guys for your help Smile

_________________
nikita bandekar
Rate this response:  
Not yet rated
chulett

Premium Poster


since January 2006

Group memberships:
Premium Members, Inner Circle, Server to Parallel Transition Group

Joined: 12 Nov 2002
Posts: 43035
Location: Denver, CO
Points: 222143

Post Posted: Wed Oct 16, 2019 6:24 am Reply with quote    Back to top    

So... it is no longer relegated to only existing in the Mainframe product? Seems I need to go scrub through the online help again. Confused

_________________
-craig

I've all my wisdom teeth, Two up top, two beneath
And yet I'll recognize my mouth says things that aren't so wise
Rate this response:  
Not yet rated
Display posts from previous:       

Add To Favorites
View next topic
View previous topic
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum



Powered by phpBB © 2001, 2002 phpBB Group
Theme & Graphics by Daz :: Portal by Smartor
All times are GMT - 6 Hours