Transformer Mapping

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
madhav62
Premium Member
Premium Member
Posts: 15
Joined: Sun Aug 15, 2010 9:26 pm

Transformer Mapping

Post by madhav62 »

i am working on mapping. I have doubt.
source column metadata are: audit_id, condition_type, condition_value
target column metadata are: audit_id, audit_type, final_value
i am using transformer, if condition_type="un audit" then audit_type= condition_value
if condidtion_type="kkk" then final_value =condition_value

how do i write it in transformer.
I tried in derivation field but it dint work out
It urgent please
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

There's a whole lecture on what is and what isn't "urgent"... I'll leave that to others.

Assuming when the condition is not met, the column would be null then derivations would be something like this:

Code: Select all

audit_id:    audit_id
audit_type:  if condition_type = "un audit" then condition_value else @NULL
final_value: if condition_type = "kkk" then condition_value else @NULL
Note that if neither of those two values are seen as the "condition_type" then both fields will be null. Of course, you can set the "not equal" condition to whatever you like.
-craig

"You can never have too many knives" -- Logan Nine Fingers
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

Please read this post carefully.

We don't do "urgent". After all, it's not urgent for us. DSXchange is an all-volunteer site whose members post when and if they can. Indeed, some of us find "urgent" requests for our unpaid time offensive. If you really do need urgent answers, sign up with your official support provider for priority service and learn just how much "urgent" is worth.
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