Joins in Server Job

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
kab123
Participant
Posts: 92
Joined: Tue May 18, 2004 4:05 pm

Joins in Server Job

Post by kab123 »

Hi ,

I am a guy of Parallel extender...We are asked to do a server job...I am little bit concerned about doing joins (like Inner Join, left Outer...etc.,) how can we specify the type of joins in server job...?
Can anyone pls hint me..?

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

Post by ray.wurlod »

The choices in server jobs are much more limited, and boil down to two; either perform the join within the passive stage that is extracting the data, or use reference lookups. The latter is necessary if the data being joined are from disparate databases.

A reference lookup can be fed from any "database" stage or from a hashed file that hash been pre-loaded from data from the probe table.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
kab123
Participant
Posts: 92
Joined: Tue May 18, 2004 4:05 pm

Post by kab123 »

As you said we can use a database stage or a hashfile stage, how can we specify what kind of join we need...if i give the condition in constraint box in transformer like lnk1.ColA=lnk2.ColA, it will become innerjoin...how about Outer Joins...

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

Post by ray.wurlod »

A reference input link is effectively a left outer join - it returns NULL in all columns if the lookup does not succeed.

You can use a constraint on the output link to prevent these rows from being further processed, turning it into an inner join.

Any right outer join can be turned into a left outer join (think on this!).

A single reference input link does not give the capability to perform a full outer join.

If the sources are in the same database, you can do any kind of join in the SQL that extracts the data from that database.

If the sources are two text files, you can do joins - any kind - using the server job's Merge stage (which I neglected to mention earlier).
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
kab123
Participant
Posts: 92
Joined: Tue May 18, 2004 4:05 pm

Post by kab123 »

Perfect ....

Thank you ver much Ray... :D
Thanks
Post Reply