How to Execute A Job or Routine in a sequence if ...

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
kkreddy
Participant
Posts: 28
Joined: Tue May 10, 2005 6:00 am

How to Execute A Job or Routine in a sequence if ...

Post by kkreddy »

How to Execute A Job or Routine in a sequence if a job is stopped intentionally by user .
I hace a senario Like

Job a ------if ok ------ job b
if failed ----jobc
if stopped by the user --- jobd
can any one help me how to catch the stop request .present i am using the joba.$JobStatus=DSJS.STOPPED which is not executing the jobd when the job stopped by the user
Thanks in Advance
KK
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

It should be joba.$JobStatus=DSJS_STOPPED actually.
-craig

"You can never have too many knives" -- Logan Nine Fingers
kkreddy
Participant
Posts: 28
Joined: Tue May 10, 2005 6:00 am

Post by kkreddy »

Job D is executing the JobA is stopped programatically .
if the user press the stop button at that time job d is not executing
can any one tell me where i am wrong


regards
KK
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

What do you mean by 'stopped programatically' exactly? Either way should generate the same status, as far as I know. :?

And I was just trying to point out that you posted the status value with a 'dot' between the two words when it actually needs to be an 'underscore'. Did you make that change?
-craig

"You can never have too many knives" -- Logan Nine Fingers
kkreddy
Participant
Posts: 28
Joined: Tue May 10, 2005 6:00 am

Post by kkreddy »

Job_Activity_3.$JobStatus = DSJS_STOPPED

i am getting the warning message Variable 'DSJS_STOPPED' never assigned a value.


Regards
Kk
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

Ok, nevermind. I was looking at the defines in the dsapi.h file where it is listed as DSJS_STOPPED. However, the trigger wants the dot in the middle or DSJS.STOPPED, so go ahead and change it back. Sorry about that. :oops:

You might still want to explain what you mean by 'stopped programatically' and if you see a different status in the Director when the job is stopped by different means. I was under the impression that both would be the same if the end result was 'Stopped', but this is not a situation I've ever tried to handle, the checking for a stopped job in a Sequence job.
-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 »

dsapi.h is intended to be used in C and C++ programs, where the "." has another meaning entirely.

For BASIC routines, use JOBCONTROL.H as the preferred header file.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

Doh! Silly Rabbit.
-craig

"You can never have too many knives" -- Logan Nine Fingers
Post Reply