Transformer condition

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
kennyapril
Participant
Posts: 248
Joined: Fri Jul 30, 2010 9:04 am

Transformer condition

Post by kennyapril »

The input to a transformer contains 8 fields
ID
year
sts
mbr
year1
sts1
year2
sts2

the output should contain only 2 fields.
ID
year (OR) year1 (OR) year2


ID remains the same
and for getting the other one below conditions should be applied

if sts--Active then "year"
else if mbr--Y
then "year"
else

if sts1---Active
then"Year1"

else
if sts2-----Active
then "year2"

Is this valid in the transformer (If Then Else) condition

pls let me know!!!
Regards,
Kenny
anbu
Premium Member
Premium Member
Posts: 596
Joined: Sat Feb 18, 2006 2:25 am
Location: india

Post by anbu »

You might need to another else statement at the end.

Try and let us know if you have problems
You are the creator of your destiny - Swami Vivekananda
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

You DO need another Else clause at the end.

If..Then..Else is an expression, and must produce a value whether or not the test expression is true.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Post Reply