Exit from a transformer

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
xcasals
Participant
Posts: 12
Joined: Thu May 27, 2004 5:50 am

Exit from a transformer

Post by xcasals »

Hello again,

I'm trying to 'exit' from a Transformer. I mean, the Transformer is generating rows from a counter. I want to say, when Counter = 1200 then exit (or stop generating data) from this transformer.

Thank you
Amos.Rosmarin
Premium Member
Premium Member
Posts: 385
Joined: Tue Oct 07, 2003 4:55 am

Post by Amos.Rosmarin »

Put your counter in a stage variable and create a constraint stageVar < 1200

if you are using @INROWNUM remamber the if the transformer does not have an input link, the first @INROWNUM is 0 !!

HTH
Amos
neena
Participant
Posts: 90
Joined: Mon Mar 31, 2003 4:32 pm

Post by neena »

You cannot end your job with transformer.
There shold be atlease one output is eeded for transformer.
Then use a stage variable and @INROWNUM condition to come out of transformer
Thanks
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

Ahh... but you can start a job with a Transformer for the purpose of generating data. This is what the OP is doing. :wink:
-craig

"You can never have too many knives" -- Logan Nine Fingers
vmcburney
Participant
Posts: 3593
Joined: Thu Jan 23, 2003 5:25 pm
Location: Australia, Melbourne
Contact:

Post by vmcburney »

You do have an @OUTROWNUM so I think you could just use a constraint @OUTROWNUM < 1201.
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

Exactly. Even starts counting from 1. :wink:
-craig

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