what is DSJ.ME ?

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
parvathi
Participant
Posts: 103
Joined: Wed Jul 05, 2006 4:48 am
Contact:

what is DSJ.ME ?

Post by parvathi »

Hi all,

please tell the use and the purpose of DSJ.ME .

hand = DSJ.ME

v_jobName = DSGetJobInfo (hand,DSJ.JOBNAME)

what does the above piece of code do?
Please tell me how to exactly use it
bkerebel
Participant
Posts: 15
Joined: Wed Jan 05, 2005 3:18 am

Post by bkerebel »

hi,
DSJ.ME is to handle a job and do some actions on it, like running the job, testing status or errors

you can find some infos in how can we reset a datastage job using datastage coding or other topics (for job control). search DSJ.ME

Bertrand
Last edited by bkerebel on Tue Feb 06, 2007 9:35 am, edited 1 time in total.
parvathi
Participant
Posts: 103
Joined: Wed Jul 05, 2006 4:48 am
Contact:

Post by parvathi »

i have declared the variable
hand = DSJ.ME

v_jobName = DSGetJobInfo (hand,DSJ.JOBNAME)
when i compile the routine i get the error

Variable 'DSJ.ME' never assigned a value.
Array 'DSGetJobInfo' never dimensioned.
WARNING: Variable 'DSJ.JOBNAME' never assigned a value.

how could i resolve this issue
DSguru2B
Charter Member
Charter Member
Posts: 6854
Joined: Wed Feb 09, 2005 3:44 pm
Location: Houston, TX

Post by DSguru2B »

Supply DSJ.ME in quotes.
Creativity is allowing yourself to make mistakes. Art is knowing which ones to keep.
ArndW
Participant
Posts: 16318
Joined: Tue Nov 16, 2004 9:08 am
Location: Germany
Contact:

Post by ArndW »

When you refer to DataStage internal variables and routines in your own job, you need to add the following line to your code:

Code: Select all

   $INCLUDE DSINCLUDE JOBCONTROL.H
bkerebel
Participant
Posts: 15
Joined: Wed Jan 05, 2005 3:18 am

Post by bkerebel »

hi,
the syntax is

v_jobName = DSGetJobInfo (DSJ.ME,DSJ.JOBNAME)

and then you can use v_jobName to do

ErrCodeRun = DSRunJob(v_jobName, DSJ.RUNNORMAL)

Bertrand
parvathi
Participant
Posts: 103
Joined: Wed Jul 05, 2006 4:48 am
Contact:

Post by parvathi »

ArndW wrote:When you refer to DataStage internal variables and routines in your own job, you need to add the following line to your code:

Code: Select all

   $INCLUDE DSINCLUDE JOBCONTROL.H
...
Thanks ..
By adding the above piece of code it works fine
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

"Me" is a very common concept in object-oriented programming - it refers to the current object. In DataStage, depending on the function, the current object may be be job, the stage, the link. In DataStage BASIC the constant DSJ.ME serves to identify the current object.
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