JCL and Jol Comparison
Simplified Jol/Oscar Language
Payroll: Job class C 1000 k;
Exec Validate
Input.Trans, Trans.Action(+1); /* Validate Transations */
if Validate=0
then do;
Sort transaction(+1) to
Sorted.Trans.Actions(+1)
Fields(10,10,CH,A);
Exec Update Payroll.Master(0),
Sorted.Trans.Action(+1),
Payroll.Master(+1);
If Update = 0
then do;
Catalog Payroll.Master(+1),
Sorted.Trans.Action(+1);
Submit Job2;
end;
end;
else Stop 'Error in PAYROLL Job';
Existing IBM Job Control Language
//PAYROLL JOB CLASS=C,REGION=1000K
//VALIDATE EXEC PGM=VALIDATE
//SYSPRINT DD SYSOUT=*
//INTRANS DD DSN=INPUT.TRANS,DISP=SHR
//OUTTRANS DD DSN=TRANS.ACTIONS(+1),DISP=(NEW,PASS),
// DCB=(RECFM=VB,LRECL=200,BLKSIZE=13030),
// SPACE=(CYL,(10,10),RLSE),
// UNIT=SYSDA,VOL=SER=WORK01
//SORT EXEC PGM=SORT,COND=(VALIDATE,NE,0)
//SYSOUT DD SYSOUT=*
//SORTWK01 DD UNIT=SYSDA,SPACE=(CYL,20)
//SORTWK02 DD UNIT=SYSDA,SPACE=(CYL,20)
//SORTWK03 DD UNIT=SYSDA,SPACE=(CYL,20)
//SORTIN DD DSN=TRANS.ACTIONS(+1),DISP=(SHR,PASS)
//SORTOUT DD DSN=SORTED.TRANS.ACTIONS(+1),
// DISP=(NEW,PASS),
// DCB=(RECFM=VB,LRECL=200,BLKSIZE=13030),
// SPACE=(CYL,(10,10),RLSE),
// UNIT=SYSDA,VOL=SER=WORK01
//SYSIN DD *
SORT FIELDS=(10,10,CH,A)
//UPDATE EXEC PGM=UPDATE,COND=(VALIDATE,NE,0)
//SYSPRINT DD SYSOUT=*
//MASTIN DD DSN=PAYROLL.MASTER(0),DISP=SHR
//TRANS DD DSN=TRANS.ACTION(+1),DISP=(SHR,PASS)
//MASTOUT DD DSN=PAYROLL.MASTER(+1),DISP=(NEW,PASS),
// DCB=(RECFM=VB,LRECL=200,BLKSIZE=13030),
// SPACE=(CYL,(10,10),RLSE),
// UNIT=SYSDA,VOL=SER=WORK01
//CATLG EXEC PGM=IEFBR14,COND=(UPDATE,NE,0)
//DUMMY1 DD DSN=PAYROLL.MASTER(+1),DISP=(SHR,CATLG)
//DUMMY2 DD DSN=SORTED.TRANS.ACTIONS(+1),
// DISP=(SHR,CATLG)
//SUBMIT EXEC PGM=IEBGENER,COND=(UPDATE,NE,0)
//SYSPRINT DD SYSOUT=*
//SYSUT1 DD DSN=SUBMIT.LIBRARY(JOB2),DISP=SHR
//SYSUT2 DD SYSOUT=(*,INTRDR)
//SYSIN DD DUMMY
//ERRMSG EXEC PGM=SHOWERR,COND=(VALIDATE,EQ,0),
// PARM='Error in PAYROLL Job'