Q.How can more than two program be executed in batch mode
through SBMJOB in CL PGM but the condition is that program
must be executed one by one?Please wtite the senario?

2. IS it possibe more then two programs can be executed in
batch mode and HOw it will be executed in CL
program ,please write the senario?

Answer Posted / amit

I think after SBMJOB of the first PGM you need to retrieve
jobd of it. When the Job is completed then SBMJOB next job.
If you submit jobs together they all are processing
simultaneously which is violation of requirements.

Your second question is not clear to me. But if it is in
continuation of the first question then yes, it is possible
to have more than two programs executed in batch mode and
you will have to continue doing RTVJOBD for submitted job
prior to submitting next job. The loop can be like-

SBMJOB (JOB1)

TAG1 : RTVJOBD (JOB1)

I am not sure which parameter is to be used but there is
one parameter that pertains to job status and If status is
complete GOTO TAG2 else got to TAG1 will give you the loop
required to implement our requirement.

TAG2 : SBMJOB (JOB2).....

you can add one as many jobs as required this way.

Is This Answer Correct ?    3 Yes 2 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Apart from opening of a file do we have any other use of USROPN?

964


what is the purpose of putovr (put with explicit override) keyword?

943


the maximum number of subfiles that can be active for a single file is ____ .

1190


what is externally described file ?

948


if we tried to move year part of *iso date into a field of length 3, what will happen ?

660






what is the use of unique keyword and what level it is defined?

931


how do u compile rpgle program?

629


Explain The Keywords Edtcde & Edtwrd?

846


How to add 99 menu (page down) option in menu creation..

1929


can error messages as a result of a comp, range or values keyword be overridden?

1145


What is diff between EVAL & MOVE?

977


what is the use of sflend keyword?

990


explain the purpose of keep and assume keywords?

1068


how may a cgi control duplicate inputs?

602


how to toggle between single line and multi - line display of a particular record in a subfile?

1094