MSGCLASS and MSGLEVEL
Two JOB statement parameters: MSGCLASS chooses the output class of the job log, and MSGLEVEL chooses how much it shows.
Also written MSGCLASS, MSGLEVEL, MSGLEVEL=(1,1), MSGCLASS=X
MSGCLASS and MSGLEVEL control the job log, the system-written part of a job's output.
MSGCLASS names the output class for the job log. The meaning of each class is set by the site: one class might be held for you to read in SDSF, another printed, another deleted after a short time. MSGCLASS=X is common in examples, but check what X means at your site, because choosing a class that is not held is a common reason a job's output seems to disappear.
MSGLEVEL has two numbers. The first controls which JCL is listed. 0 lists only the JOB statement, 1 lists all the JCL including what came from PROCs, and 2 lists only the JCL you submitted. The second controls messages. 0 shows allocation messages only if the job fails, and 1 always shows them.
MSGLEVEL=(1,1) shows everything, which is what you want while developing and supporting jobs. When a job fails and its log seems to be missing information, check MSGLEVEL first.
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
- JOB statementThe first statement in every job, giving it a name and telling the system who is running it and how to treat it.
- Job logThe part of a job's output written by the system rather than the program: what happened to the job, step by step.
- SYSOUTOutput sent to the spool rather than to a dataset, where you can read it after the job finishes.
- Held outputJob output kept on the spool for you to look at instead of being printed, or a job kept waiting until it is released.
- SpoolThe system-managed holding area where job output waits to be read, printed or purged.