$Projdef

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
pongal
Participant
Posts: 77
Joined: Thu Mar 04, 2004 4:46 am

$Projdef

Post by pongal »

Hi,
i have read some posts regarding $Projdef project specific env variable.
i am not still understanding the use of $Projdef env variable.
how to use exactly this variable ?
i have created some env variables at dsadmin like
$Par_SrcFilePath
$Par_TrgFilePath
$Par_remoteUserID
$SRC_DBNAME etc where some of the env variables have values that does not change in all the environments (DEV,INT,PROD)
where can i define all the static env variables using $Projdef ?
tusharzade
Participant
Posts: 13
Joined: Wed Dec 15, 2004 2:19 am

Re: $Projdef

Post by tusharzade »

Hi Pongal,

$PROJDEF is a default value assigned in the job parameter of any Datastage job. Now consider the scenario where administrator wants to keep some password which should not be accessed by the developer. Then in this scenario administrator can set the password for Suppose DB login in a administraor for user defined varialble. Then You can use the same variable in your job but with the default value as $PROJDEF. So that whenever you administrator wants to change the password he do not need to inform you. Your job will take the value which is defined in the administrator.

Regards,
Tushar
PhilHibbs
Premium Member
Premium Member
Posts: 1044
Joined: Wed Sep 29, 2004 3:30 am
Location: Nottingham, UK
Contact:

Re: $Projdef

Post by PhilHibbs »

Which version of DS are you using? $Projdef doesn't work on 7.0.1.
Phil Hibbs | Capgemini
Technical Consultant
pongal
Participant
Posts: 77
Joined: Thu Mar 04, 2004 4:46 am

Post by pongal »

i am using DataStage v 7.5.1a.
i have another doubt that using $Projdef, can we define any number of user defined env variables ?
how could we define the below user defined env variables having default values using $Projdef?
$Par_SrcFilePath
$Par_TrgFilePath
$Par_remoteUserID
$SRC_DBNAME
trokosz
Premium Member
Premium Member
Posts: 188
Joined: Thu Sep 16, 2004 6:38 pm
Contact:

Post by trokosz »

You define the user defined environment variables in Administrator. Now give them the values you want. Then when you create your Job in Designer you select those environment variables relevant that you defined....and for the value you say $PROJDEF or it gets the value entered in Administrator.

Now this comes to a big topic on how to change environment variables without entering dataStage....or creating a *.ini or *.config file that is inherited by DataStage.....but thats not what you asked but consider it.....

There is a known bug with $PROJDEF and that is if you use this technique and use the DRS Stage.....then then View data on the DRS Stage fails.....

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

Post by vmcburney »

There is a FAQ on this topic. You can read it at:
viewtopic.php?t=92038

Or you can view the modifiable version at:
http://wiki.ittoolbox.com/index.php/HOW ... _variables
Post Reply