Need Logic

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
raju4u
Participant
Posts: 56
Joined: Thu Dec 13, 2007 12:30 am

Need Logic

Post by raju4u »

Hi All,

My input is like
1,gg,3
2,hh,2
3,hh,1

3rd column name is value an my output should display according to the value of that colmn.


here o/p i slike
1,gg,3
1,gg,3
1,gg,3
2,hh,2
2,hh,2
3,hh,1

Can anybody help me the logic for the above.

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

Post by ray.wurlod »

Use the looping construct in the version 8.5 Transformer stage. It's an ideal usage for this functionality.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
raju4u
Participant
Posts: 56
Joined: Thu Dec 13, 2007 12:30 am

Need Logic

Post by raju4u »

HI Ray,

Thanks for the information ,cant we do in the 8.1 version.Please let me know any work around.
N R REDDY
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

I would look into setting up the data so you could then perform a horizontal pivot. For example:

1,gg,3 -> 1,gg,3,gg,3,gg,3
2,hh,2 -> 2,hh,2,hh,2

Set up the max number of columns and then pivot the result.
-craig

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