NOt in look up

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
kkreddy
Participant
Posts: 28
Joined: Tue May 10, 2005 6:00 am

NOt in look up

Post by kkreddy »

Hi Gurus ,
can any one help me
how to implement the following query in DSEE as i am new to Datastage

SELECT distinct col1,col2,col3 FROM tableA
WHERE ( AP > 0 or SP > 0 ) and lf = '01' and
ce = '01' and rd = '00'and col1 not in
( select col1 from tableA where col4 = '01' and
col5 = '01' and col6 = '00' and fdate = 200673 ) and period = 200673

i want to know how to lookup not in records

Thanks in advance
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

What's wrong with loading the result from that query into a Lookup File Set, and using the same for performing your lookup? It's unclear from that SQL what key value will be being looked up, but I am confident you know which column that is.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
DSguru2B
Charter Member
Charter Member
Posts: 6854
Joined: Wed Feb 09, 2005 3:44 pm
Location: Houston, TX

Post by DSguru2B »

Yea, just pass that sql command from your database stage. Even that is called "Implementing in DataStage".
Creativity is allowing yourself to make mistakes. Art is knowing which ones to keep.
us1aslam1us
Charter Member
Charter Member
Posts: 822
Joined: Sat Sep 17, 2005 5:25 pm
Location: USA

Re: NOt in look up

Post by us1aslam1us »

kkreddy wrote: i want to know how to lookup not in records
Hi Reddy

Do u mean to lookup against the records which are the rejects from the database after executing the query or something else. If you just want to execute the query and do a lookup, you can do that as suggested by Ray and DSguru orelse you have to catch the rejects from the database and do the lookup against it.

Just your last sentence is not clear.

Thanks
Sam
Post Reply