Problem while passing parameter from one job to another

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
Das
Participant
Posts: 87
Joined: Tue Oct 24, 2006 9:58 pm
Location: india

Problem while passing parameter from one job to another

Post by Das »

Hi,
I am have some proble while passing parameter from one job to another
using the following manner

UtilityRunJob('testJob', 'Par1=' : DSLink4.o_p_uid :'|' : 'DataSource=' : DSGetParamInfo(DSJ.ME,DataSource,DSJ.PARAMTYPE.STRING))

I am calling testJob from job ABCD par1 is taking from a file and the DataSource is a prameter from the job ABCD which i have to pass to test job
While runnig i am getting the error as follows in director
ABCD..Transformer_3 (UtilityRunJob): Setting Job Param - DataSource Setting to -3 and then the job got aborted

Please help me out in this .
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

Use DSJ.PARAMVALUE instead of DSJ.PARAMTYPE.STRING
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Das
Participant
Posts: 87
Joined: Tue Oct 24, 2006 9:58 pm
Location: india

Post by Das »

ray.wurlod wrote:Use instead of DSJ.PARAMTYPE.STRING ...
I have used DSJ.PARAMVALUE but still giving the same error.
Please suggest any alternative
clarcombe
Premium Member
Premium Member
Posts: 515
Joined: Wed Jun 08, 2005 9:54 am
Location: Europe

Post by clarcombe »

Have you tried to put an actual value instead of the parameter ?
e.g.

UtilityRunJob('testJob', 'Par1=' : DSLink4.o_p_uid :'|' : 'DataSource=' : '<hard coded value')

Try this and see if you still get the same error. If you are, then it is possibly a problem with your routine
Colin Larcombe
-------------------

Certified IBM Infosphere Datastage Developer
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

You don't need to pull the value like that. Not for this situation. :?

Just use it:

Code: Select all

UtilityRunJob('testJob', 'Par1=' : DSLink4.o_p_uid :'|' : 'DataSource=' : #DataSource#)) 
-craig

"You can never have too many knives" -- Logan Nine Fingers
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

Code -3 (DSJE.BADPARAM) means "bad parameter name" - that is, the parameter NAME that you are giving is not the name of a parameter in that job. Check both spelling and casing.
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