Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

PRESENT Subtask in Batch Table

Status
Not open for further replies.

payers

MIS
Sep 21, 2000
17
AU
I have a problem trying to use this subtask in our unix system. The documention states that there are three options to use if the file that is being checked for is missing (-error [ABORT](NEXT)[CONTINUE]). This functionality does not appear to work for us as the process creates an 'ABORT' status whenever a file is missing even though we use '-error NEXT' which should stop the current task and continue to the next task. Can someone lead me to the script / macro that controls this. I have looked ant keyword.pl that manages the subtask functionality but it does not handle the error checking. Any help would be appreciated.
 
Which stream in the batch.tbl? I have experienced problems in the past in the Report stream using KEYWORDS. If you have your tasks in the Report stream, try moving them to the Online and/or Update stream
 
GBell
The problems I am having are with tasks that are in the Update and Online streams. I am having problems finding the code that should manage the error handling. Maybe it is an environment specific problem. Any ideas anyone?
 
The code you are looking for may be within mimsbatch.pl look for ERR_ABORT and ERR_CONT,
however I do not seem to understand from your description what you are trying to achieve, maybe you wish to post a copy of you batch task entries.

If you have a PRESENT sub-task to check for the existence of a file, it does not make sense to attach "-error" in the sense you describe, because this negates the purpose of PRESENT which is exactly to stop further processing if a file does not exist; If you wish to continue with processing regardless, you do not need a PRESENT sub-task.

But maybe your interpretation of NEXT is incorrect?
My documentation states that:
"NEXT" is the default behaviour, which means that if an error occurs in a subtask-the rest of the task is ended, and processing continues with the NEXT task NOT SUBTASK. Therefore you do NOT need to code for -error NEXT explicitely, this is the default.

ABORT is a stream control and will abort the ENTIRE stream (Update, report, online) - so use carefully

CONTINUE is probably what you are after, it means that if a sub-task aborted, it will not cause the task to end, processing continues with next sub-task within the task.

However it does not make sense to use PRESENT with - error continue, as explained.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top