"Transformer Stage Constraint" to be parameterised

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
tkbharani
Premium Member
Premium Member
Posts: 71
Joined: Wed Dec 27, 2006 8:12 am
Location: Sydney

"Transformer Stage Constraint" to be parameterised

Post by tkbharani »

DearAll

In transformer stage constraint I am using the following condition by passing a value ,through which the data is segregated and populated in a file. This value must be parameterised. I am using this in transformer stage constraint.How to Do this.

Example : Month=12

This "12" value must be passed as a parameter, as this changes every month.
Thanks, BK
WoMaWil
Participant
Posts: 482
Joined: Thu Mar 13, 2003 7:17 am
Location: Amsterdam

Post by WoMaWil »

Look into the Manual or go to a training session.

Code: Select all

Month=pMonth
Wolfgang Hürter
Amsterdam
sachin1
Participant
Posts: 325
Joined: Wed May 30, 2007 7:42 am
Location: india

Re: "Transformer Stage Constraint" to be parameter

Post by sachin1 »

i agree with WoMaWil , where the code is to be put in constraint of transformer stage to populate values in target seq file according to your parameterized month value.
tkbharani
Premium Member
Premium Member
Posts: 71
Joined: Wed Dec 27, 2006 8:12 am
Location: Sydney

Post by tkbharani »

Do I have to use Data Element or Month.tag.
Give a some suggestion so that I can search or proceed through the method.
Thanks, BK
baglasumit21
Participant
Posts: 132
Joined: Wed Mar 01, 2006 11:12 pm
Location: Pune

Re: "Transformer Stage Constraint" to be parameter

Post by baglasumit21 »

tkbharani wrote:DearAll

In transformer stage constraint I am using the following condition by passing a value ,through which the data is segregated and populated in a file. This value must be parameterised. I am using this in transformer stage constraint.How to Do this.

Example : Month=12

This "12" value must be passed as a parameter, as this changes every month.
Just declare a parameter say Month_param and use is in the constraint as

Month = Month_param.

Whats the difficulty in this?
SMB
lokesh_vee
Participant
Posts: 3
Joined: Tue Oct 23, 2007 11:57 pm

Post by lokesh_vee »

Is the column what used for the constraint is it an integers (for example: 1, 2, ----, 11, 12) or it is a date column?

If the column being reference in the constraint is integer the suggestion provided above should be followed.

If the column being reference is a date then use the code below to fetch the month number. There are methods of achieving the same result.

Oconv(Iconv(Inp_Data.Date,"D2/"), "DM")=pMonth

pMonth is the job parameter.
Masters are never born. But they become one by experience.
Post Reply