Job Active stage custom exp job staus (0,1,2,3) refer to?

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
dsguy
Participant
Posts: 34
Joined: Thu Mar 09, 2006 10:37 am

Job Active stage custom exp job staus (0,1,2,3) refer to?

Post by dsguy »

Hi

I want to add a job active variable in custom expression in the job active stage of a sequence. Plese let me know the return code of jobstatus fos succuss ,warning ,abort.also Please let me know what does 0,1,2,3 refer to in job active stage.

Thanks
aakashahuja
Premium Member
Premium Member
Posts: 210
Joined: Wed Feb 16, 2005 7:17 am

Post by aakashahuja »

1 success
2 finished with warning
3 abort
kumar_s
Charter Member
Charter Member
Posts: 5245
Joined: Thu Jun 16, 2005 11:00 pm

Post by kumar_s »

You mean JobActivity?

Code: Select all

Equ DSJS.RUNNING     To  0 ;* This is the only status that means the job is actually running
   Equ DSJS.RUNOK       To  1 ;* Job finished a normal run with no warnings
   Equ DSJS.RUNWARN     To  2 ;* Job finished a normal run with warnings
   Equ DSJS.RUNFAILED   To  3 ;* Job finished a normal run with a fatal error
   Equ DSJS.VALOK       To 11 ;* Job finished a validation run with no warnings
   Equ DSJS.VALWARN     To 12 ;* Job finished a validation run with warnings
   Equ DSJS.VALFAILED   To 13 ;* Job failed a validation run
   Equ DSJS.RESET       To 21 ;* Job finished a reset run
   Equ DSJS.CRASHED     To 96 ;* Job has crashed
   Equ DSJS.STOPPED     To 97 ;* Job was stopped by operator ntervention (can't tell run type)
   Equ DSJS.NOTRUNNABLE To 98 ;* Job has not been compiled
   Equ DSJS.NOTRUNNING  To 99 ;* Any other status
Impossible doesn't mean 'it is not possible' actually means... 'NOBODY HAS DONE IT SO FAR'
dsguy
Participant
Posts: 34
Joined: Thu Mar 09, 2006 10:37 am

Post by dsguy »

Thanks a lot .
This is what i need :D
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

And rather than checking the status for its numeric value, you are better off using the equated value. For example, instead of:

Code: Select all

JobActivity.$JobStatus = 1
Use:

Code: Select all

JobActivity.$JobStatus = DSJS.RUNOK
Not only is it more 'future proof' but it also uses the meaning of the number (which is what you really care about, not the number itself) and so reads easier.
-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 »

I believe the OP is also asking about stage status. This can be waiting (yellow link), running (blue link), finished (green link), aborted (red link). Unless you've customized the colours.
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