Change Job Status

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
its_me48
Participant
Posts: 33
Joined: Fri Apr 29, 2005 10:09 am

Change Job Status

Post by its_me48 »

I am running a sequence job which starts with extract (unix script) and if extract fails I want to change the job status to "failed". Right now, even if the extract fails, the job sends out email and job status is "finished". How do I make it fail when extract fails.

Thanks,
-Sam
gateleys
Premium Member
Premium Member
Posts: 992
Joined: Mon Aug 08, 2005 5:08 pm
Location: USA

Re: Change Job Status

Post by gateleys »

its_me48 wrote:I am running a sequence job which starts with extract (unix script) and if extract fails I want to change the job status to "failed". Right now, even if the extract fails, the job sends out email and job status is "finished". How do I make it fail when extract fails.

Thanks,
-Sam
Use an Exception Handler, with the job properties set to 'Automatically Handle Failures'. Connect it to a Notification and then to a Terminator stage. You should be good. Alternatively, use the Failed Trigger to Notify and then call UtilityAbortToLog.

gateleys
its_me48
Participant
Posts: 33
Joined: Fri Apr 29, 2005 10:09 am

Re: Change Job Status

Post by its_me48 »

Thank You !!
gateleys wrote:
its_me48 wrote:I am running a sequence job which starts with extract (unix script) and if extract fails I want to change the job status to "failed". Right now, even if the extract fails, the job sends out email and job status is "finished". How do I make it fail when extract fails.

Thanks,
-Sam
Use an Exception Handler, with the job properties set to 'Automatically Handle Failures'. Connect it to a Notification and then to a Terminator stage. You should be good. Alternatively, use the Failed Trigger to Notify and then call UtilityAbortToLog.

gateleys
Post Reply