LINK COLLECTOR - INPUT COLUMN ORDER

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
snt_ds
Premium Member
Premium Member
Posts: 280
Joined: Wed Oct 18, 2006 11:53 am
Location: Pune, India

LINK COLLECTOR - INPUT COLUMN ORDER

Post by snt_ds »

Hi,

When we use 2 input links to a Link Collector stage, is it necessary to have the same name & total number of cols and also the same ORDERING of cols or if all the column names ( & number) are same in both INPUT links but the ordering is different it will still work correctly?

e.g

INPUT 1 - COL1 COL2 COL3 (3 cols)
INPUT 2 - COL1 COL3 COL2 (3 cols)

OUTPUT COL1 COL2 COL3 (3 cols)

Thanks,
NV
ravimetla
Participant
Posts: 8
Joined: Thu May 19, 2005 10:45 am

Re: LINK COLLECTOR - INPUT COLUMN ORDER

Post by ravimetla »

Hi,

You should have same order of columns but not the order of links unless you want to maintain any kind of sort in the output
RM
snt_ds
Premium Member
Premium Member
Posts: 280
Joined: Wed Oct 18, 2006 11:53 am
Location: Pune, India

Post by snt_ds »

What do mean same order of columns but not order of links?

I am using SORT/MERGE in the stage.
My question is does the ORDER of cols need be the same on both input links?
Pls see example
snt_ds
Premium Member
Premium Member
Posts: 280
Joined: Wed Oct 18, 2006 11:53 am
Location: Pune, India

Post by snt_ds »

What do mean same order of columns but not order of links?

I am using SORT/MERGE in the stage.
My question is does the ORDER of cols need be the same on both input links?
Pls see example
ravimetla
Participant
Posts: 8
Joined: Thu May 19, 2005 10:45 am

Post by ravimetla »

Definitely you need to have order of columns
RM
srimitta
Premium Member
Premium Member
Posts: 187
Joined: Sun Apr 04, 2004 7:50 pm

Post by srimitta »

Yes, Columns need to in same order.

INPUT 1 - COL1 COL2 COL3 (3 cols)
INPUT 2 - COL1 COL2 COL3 (3 cols)

OUTPUT COL1 COL2 COL3 (3 cols)
Quality is never an accident; it is always the result of high intention, sincere effort, intelligent direction and skillful execution; it represents the wise choice of many alternatives.
By William A.Foster
sachin1
Participant
Posts: 325
Joined: Wed May 30, 2007 7:42 am
Location: india

Post by sachin1 »

column order in input can vary.
snt_ds
Premium Member
Premium Member
Posts: 280
Joined: Wed Oct 18, 2006 11:53 am
Location: Pune, India

Post by snt_ds »

Well, the answer to my question is both YES & NO from different people.

I think as far as the COLUMN NAMES and NUMBER (count) is same on both input links, it should be fine. The order may Vary.

I am getting an issue with this in the result and hence I am posting this query
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

The help simply says "Note that the meta data on all input links must be identical, and this in turn must be identical to the meta data on the output link". Interpret that as you will, but I don't see the problem with ensuring everything is identical including the column order. Drag the link, Luke.
-craig

"You can never have too many knives" -- Logan Nine Fingers
ravimetla
Participant
Posts: 8
Joined: Thu May 19, 2005 10:45 am

Post by ravimetla »

hi,

you could get better result if you switch the order of col 2 and col 3 from input link before going to collector stage... for ex: by a transformer
RM
sachin1
Participant
Posts: 325
Joined: Wed May 30, 2007 7:42 am
Location: india

Post by sachin1 »

sorry for my previous post, output has some problem, i does take any order in input but output is wrong.
snt_ds
Premium Member
Premium Member
Posts: 280
Joined: Wed Oct 18, 2006 11:53 am
Location: Pune, India

Post by snt_ds »

OK..I will give it a try with EVERYTHING IDENTICAL

Thanks All
snt_ds
Premium Member
Premium Member
Posts: 280
Joined: Wed Oct 18, 2006 11:53 am
Location: Pune, India

Post by snt_ds »

Yes, The COLUMN ORDER needs to be the same too.
Post Reply