jcs.return_code
PL/SQL API jcs.return_code
Summary
Return the numerical value returned by the job when it finished or was killed.
In most scripting languages, this is set by 'exit <n>'.
The exact numerical values returned are operating system and job dependent.
Specification
function return_code(job_id in number)
return number
Parameters
- job_id - the ID of the job
- returns number - value returned by the job
Transaction keyword
The transaction keyword defines how and/or when the changes are committed to the database. A definition of the various transaction keywords can be found on the jcs package summary page.
none
Examples
Using jcs.return_code
...
jcs.submit(...);
commit;
jcs.wait(...);
if jcs.job_statuscode(jcs.last_job_id) <> 'C'
then
jcs_out.put_line('Job terminated with error: '
|| jcs.return_code(jcs.last_job_id);
end if;
...