JCL error
A job that fails before running any program, because the JCL itself is wrong or something it names cannot be found.
Also written JCL ERROR, JCL syntax error, IEFC messages
A JCL error means the job failed because of its JCL, not because of a program. SDSF shows JCL ERROR in place of a return code, and often no step ran at all.
There are two kinds. Syntax errors are found when the JCL is read: a misspelled keyword, a missing comma, an unmatched bracket, text past column 71. Their messages start with IEFC, such as IEFC605I for an unknown statement type. Allocation errors are found when a step is about to start: a dataset that does not exist, a dataset that is already catalogued when the JCL says NEW, or a missing DD for a required file. Messages such as IEF212I explain them.
The job log holds the answer. Look in JESMSGLG for the error, then JESYSMSG, where the message appears next to the statement that caused it.
Fix the JCL and submit it again. For syntax errors, TYPRUN=SCAN finds most of them without running the job. JCL errors are frustrating at first, but the messages are precise, and reading them carefully usually points straight to the line.
Where can I learn this hands-on?
Right here, at ZedBank. You take a junior job at a simulated bank and learn each part of the work by doing it, with Zed beside you. There's nothing to install.
Start at ZedBankRelated
- JCLJob Control Language: the language used to tell the mainframe what programs to run, in what order, and with what files.
- Job logThe part of a job's output written by the system rather than the program: what happened to the job, step by step.
- SDSFThe tool for looking at what jobs are running, what has finished, and what output they produced.
- Return codeA number a program leaves behind saying how it went. Zero for clean, higher numbers for warnings and failures.
- TYPRUNA JOB statement parameter that changes how a job is handled, most often to check its JCL without running it, or to hold it.
- IEF212IA message that says a DD statement named a dataset the system could not find, so the step did not run.