Reference link with multi row - OCI stage

Post questions here relative to DataStage Server Edition for such areas as Server job design, DS Basic, Routines, Job Sequences, etc.

Moderators: chulett, rschirm, roy

Post Reply
dprasanth
Charter Member
Charter Member
Posts: 90
Joined: Fri Oct 07, 2005 7:55 am

Reference link with multi row - OCI stage

Post by dprasanth »

Hi,
I am using OCI stage for reference Lookup. I need to select multiple row result set from the lookup. I tried opening the tranform stage, right clicked on the title of the reference link and choose link properties. But couldn't find the checkbox "Reference link with multi row result set" checkbox. Then found out that it is applicable only for ODBC stages.

So just wondering what is the best way to achieve multiple row result using OCI stage?

Thanks in Advance.
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

As you've found, that can't be done with an OCI lookup as that option is only applicable when using ODBC or a UV stage. For a 'pure' Oracle solution, I prefer to load the 'source' information into a work table and join that to the lookup table(s) so that the 'multi-row result set' is what streams in as input to the job.
Last edited by chulett on Wed Oct 03, 2007 7:55 am, edited 1 time in total.
-craig

"You can never have too many knives" -- Logan Nine Fingers
dprasanth
Charter Member
Charter Member
Posts: 90
Joined: Fri Oct 07, 2005 7:55 am

Post by dprasanth »

chulett wrote:As you've found, that can't be done with an OCI lookup as that option is only applicable when using ODBC or a UV stage. For a 'pure' Oracle solution, I prefer to load the 'lookup' information into a work table and join that to the source table(s) so that the 'multi-row result set' is what streams in as input to the job.
I really appreciate your quick response.

My INPUT is a SEQUENTIAL FILE STAGE and LOOKUP is a user defined sql in OCI stage(three tables are joined here). My input file has FIRSTNAME and SURNAME as the input field and I lookup and if it is found I get a list of other columns from the lookup OCI. The only reason I cannot use the lookup as the work table is , I will get million of records and obviously I cannot join that with my Input sequential stage right? But I can do one thing, I can put all the records from the input file to a oracle table and then can join that with the lookup sql. I will try that and will let you know. Once again, thanks a lot!
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

dprasanth wrote:But I can do one thing, I can put all the records from the input file to a oracle table and then can join that with the lookup sql. I will try that and will let you know. Once again, thanks a lot!
Actually, that's exactly what I meant. :wink:

Edited the original post to (hopefully) be more clear.
-craig

"You can never have too many knives" -- Logan Nine Fingers
Post Reply