Page 1 of 1

After Job Sub rouitne

Posted: Mon Jun 25, 2007 9:59 am
by dspxguy
I have a job in the sequence which uses a after job sub routine to kick of a shell script which does an insertion in a table used by another job.

How can I get the status of the script using a routine activity stage (whether it ran successfully or not?)

Thanks in advance.

Posted: Mon Jun 25, 2007 10:28 am
by ArndW
The after job subroutine does not have a separate status, it's return status sets that of the job. If you need to use the return value of the script from the after job subroutine you could look into setting the user status.

Posted: Mon Jun 25, 2007 10:42 am
by dspxguy
Thanks for the reply Andrw

Can you please elaborate more on setting the user status..

Cheers

Posted: Mon Jun 25, 2007 10:53 am
by ArndW
The BASIC Programmer's Guide documents the syntax for the DSSetUserStatus() function call, and you can query the value with the DSGetJobInfo() function.