Best practices for user defined environment variables.

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
verify
Premium Member
Premium Member
Posts: 99
Joined: Sun Mar 30, 2008 8:35 am

Best practices for user defined environment variables.

Post by verify »

Hi there,

Could please tell me what is best way to maintain user defined variables in DataStage 8.0.

Is it better to create parameter sets or defining user defined variables in datastage admin? if so, what are the pros & cons.

And also one more question,

I have 300 jobs in my project, i have called apt_config_file environment variable in every job, this apt_config_file file path is changed every time when i migrate datastage jobs to deferent environment like QA or Production so now my problem is every time I have to open the job and change the path of the apt_config_file, it is very huge task to open each and every job and changing the path and compile the job. Can anyone suggest how to avoid this type of problems.
RK Raju
ag_ram
Premium Member
Premium Member
Posts: 524
Joined: Wed Feb 28, 2007 3:51 am

Re: Best practices for user defined environment variables.

Post by ag_ram »

verify wrote:I have 300 jobs in my project, i have called apt_config_file environment variable in every job, this apt_config_file file path is changed every time when i migrate datastage jobs to deferent environment like QA or Production so now my problem is every time I have to open the job and change the path of the apt_config_file, it is very huge task to open each and every job and changing the path and compile the job. Can anyone suggest how to avoid this type of problems.
The values for all Environment variables(default and user defined) which are in the Adminstrator, are set initially, when you run the Job.

So there is no need to add the Environment variable APT_CONFIG_FILE for each Job(likely to be in Dev, Tst, Prd) and change the location instead, you can change the default location of the that variable in the respective project/server(Dev, Tst, Prd) using DS Adminstrator.
mahadev.v
Participant
Posts: 111
Joined: Tue May 06, 2008 5:29 am
Location: Bangalore

Post by mahadev.v »

Set the value for all the environmental variables to $PROJDEF. If you run the job then the value for APT_CONFIG_FILE is the same as the project default. Even if the job is moved to a new environment, you can just run the job, and the value defaults to the project default. And at run time you can also pass a different value for the variable.
"given enough eyeballs, all bugs are shallow" - Eric S. Raymond
Post Reply