Multiple choice technology programming languages

Which one of the following keyword a PROC cannot have?

  1. EXEC

  2. SYSABEND

  3. JOBLIB

  4. SYSPRINT

Reveal answer Fill a bubble to check yourself
C Correct answer
Explanation

JOBLIB is a JCL statement (not a keyword on EXEC) that must appear before the first EXEC statement in a job. The keywords EXEC, SYSABEND, and SYSPRINT can all be used on PROC EXEC statements. JOBLIB is used at the job level, not within a PROC.

AI explanation

In JCL, a cataloged/in-stream PROC (procedure) cannot contain a JOBLIB DD statement — JOBLIB is only valid at the job step level (in the EXEC JCL that invokes the job), because it applies library search order to the entire job, not to an individual procedure step. Within a PROC, the equivalent function is achieved with STEPLIB instead. EXEC (to invoke a program), SYSABEND (for abend dumps), and SYSPRINT (for print output) are all perfectly valid DD/statement names that can appear within a PROC. So JOBLIB is correctly identified as the keyword a PROC cannot have.