Using 'otherwise' in a transformer

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
PilotBaha
Premium Member
Premium Member
Posts: 202
Joined: Mon Jan 12, 2004 8:05 pm

Using 'otherwise' in a transformer

Post by PilotBaha »

I have been using 'otherwise' to capture the records that don't meet the criteria in a transformer for so many years. Just today found out that some records that should meet the requirement are being captured by 'otherwise' link on a Transformer. I displayed every single criteria in the output files and I still couldn't believe my eyes that 'otherwise' had some data that should have gone the other way.
Even using stage variable didn't solve the problem until I explicitly typed
StageVar = 0 in the contraint section of the former 'otherwise' link.

Am I missing something?
Earthbound misfit I..
Sainath.Srinivasan
Participant
Posts: 3337
Joined: Mon Jan 17, 2005 4:49 am
Location: United Kingdom

Post by Sainath.Srinivasan »

Check link order
tjr
Participant
Posts: 19
Joined: Wed Jun 15, 2005 6:37 am

Re: Using 'otherwise' in a transformer

Post by tjr »

What exactly were your constraints previously?
Remember that StageVar = 0 is in some cases equal to not(StageVar)...
mk_ds09
Participant
Posts: 72
Joined: Sun Jan 25, 2009 4:50 pm
Location: Pune

Post by mk_ds09 »

Can you check the data which you think that could have gone the other way...!

If the data is present on both links then you can say that there is issue with the other way...and it is only in the 'Otherwise'..it cleary failing some criteria to go in the first link..

---------------------

Hope this helps..

-------------------

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

Post by ray.wurlod »

What is the data type of the stage variable? Remember that parallel jobs are strongly typed. One result of this is that any constraint expression must evaluate to a true/false value; the old server way of thinking (0 is false, anything else is true) does not apply here.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
dr.murthy
Participant
Posts: 224
Joined: Sun Dec 07, 2008 8:47 am
Location: delhi

Post by dr.murthy »

Sainath.Srinivasan wrote:Check link order

The other wis link always be last order,if at all not in that case there is a chance to get some additonal records
D.N .MURTHY
Post Reply