Passing stage variable to a parameter

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
halpavan2
Participant
Posts: 31
Joined: Fri Apr 18, 2008 5:44 am
Location: Hyderabad

Passing stage variable to a parameter

Post by halpavan2 »

Hello All,

My requirment is:

I am loading the data toa file and passing the file name like this. #Tempfilepath#/#subject#.txt, Here i am getting #Tempfilepath# from parameters, but #subject# is not defined in the parameters.

I want to extract the Subject from the tempfilepath sya suppose. \data\ds\1234 here my subject will be 1234, this i will trim in the transformer stage in the stage varibles and get the subject name.

The reason why i don't want to pass as a paramter is it is shared container which is already using in so many jobs, if i now add extra param then i need to pass the parameter in all the jobs which i am using. That's why i am looking for an alternate solution.

How can i pass this subject name to the file name? Is it possible. If yes let me know in brief how can i do that. any alternate solution how to implement this.


Thanks in Advance
pavan
Post Reply