Constraint as a Stage Variable

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
gateleys
Premium Member
Premium Member
Posts: 992
Joined: Mon Aug 08, 2005 5:08 pm
Location: USA

Constraint as a Stage Variable

Post by gateleys »

I have the same constraint for outlink1 and outlink2. Now, I have 2 simple ways of enforcing the constraint-
1. Specify the same in the constraint field of outlink1 and also in outlink2.
2. Or, I could declare a stage variable, svMyConstraint, whose derivation field contains the constraint. And, the stage variable svMyConstraint is specified as the constraint in each output links.

My question is: In the second method, for every row, will the constraint be computed ONLY ONCE for svMyConstraint, and evaluate TRUE/FALSE for the output links?

In simpler terms, will the first method execute 2 times (once for each output link), and the second method execute only once?

Thanks.
gateleys
ArndW
Participant
Posts: 16318
Joined: Tue Nov 16, 2004 9:08 am
Location: Germany
Contact:

Post by ArndW »

Use the stage variable, it will only be computed once per row.
gateleys
Premium Member
Premium Member
Posts: 992
Joined: Mon Aug 08, 2005 5:08 pm
Location: USA

Post by gateleys »

Thanks Arnd.
Post Reply