Pick the environment variable file dynamically

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
sumeet
Premium Member
Premium Member
Posts: 54
Joined: Tue Aug 30, 2005 11:44 pm

Pick the environment variable file dynamically

Post by sumeet »

Hi,

We have jobs which has environment variable file -- "dsenv".

Now we want to run the same set of jobs with different environment variable file -- "dsenv1".

The jobs are called from parent sequencers which are in turn kicked off by a shell script(command line).

Is there any way to set which environment variable file is picked for which run. e.g
I want to run the jobs today with dsenv file & tomorrow with dsenv1 file.

There are around 700 jobs. So rather then changing the jobs for 2 parameters we felt its better to make different environment variable file

If its possible where do we set this environment variable file to be picked up dynamically and how??

Thanks
Sumeet
vmcburney
Participant
Posts: 3593
Joined: Thu Jan 23, 2003 5:25 pm
Location: Australia, Melbourne
Contact:

Post by vmcburney »

The dsenv file is not the best place for dynamic variables like this. I would consider having different batch user ids for each of the two runs and give each id values in a .profile file. Also consider pushing the two job parameters into all jobs and passing the values in from the calling script via the dsjob command.
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

To use dsenv is hard coded in DataStage.

To use additional environment variables files is possible, whether through an Execute Command activity early in a job sequence or possibly by sourcing from dsenv itself.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Post Reply