Jobs And Job Control Language - IBM Mainframe

Simply put, a job is the execution of one or more related programs in sequence. Each program to be executed by a job js called a job step. To illustrate, suppose you want to process a job that executes two programs-the first sorts a customer file into customer name sequence, and the second prints a report that lists customers by name. That is a two-step job because two programs are required. When you submit a job to be processed by MVS, the job is treated as a whole. The job begins with the execution of the first program and continues until the last program has finished executing, unless an unforeseen error condition occurs.

Job Control Language(JCL) is ascripting languageused onIBM mainframeoperating systems to instruct the system on how to run abatch jobor start a subsystem.

There are actually two IBM JCLs: one for the operating system lineage that begins withDOS/360and whose latest member isz/VSE; and the other for the lineage fromOS/360toz/OS. They share some basic syntax rules and a few basic concepts, but are otherwise very different.

In both JCLs the unit of work is the job. A job consists of one or several steps, each of which is a request to run one specific program. For example, before the days ofrelational databases, a job to produce a printed report for management might consist of the following steps: a user-written program to select the appropriate records and copy them to a temporary file;sortthe temporary file into the required order, usually using a general-purpose utility; a user-written program to present the information in a way that is easy for the end-users to read and includes other useful information such as sub-totals; and a user-written program to format selected pages of the end-user information for display on a monitor or terminal.

In both DOS and OS JCL the first "card" must be the JOB card, which:

  • Identifies the job.
  • Usually provides information to enable the computer services department to bill the appropriate user department.
  • Defines how the job as a whole is to be run, e.g. its priority relative to other jobs in the queue.

Procedures (commonly calledprocs) are pre-written JCL for steps or groups of steps, inserted into a job. Both JCLs allow such procedures. Procs are used for repeating steps which are used several times in one job, or in several different jobs. They save programmer time and reduce the risk of errors. To run a procedure one simply includes in the JCL file a single "card" which copies the procedure from a specified file, and inserts it into the jobstream. Also, procs can includeparametersto customize the procedure for each use.

All rights reserved © 2018 Wisdom IT Services India Pvt. Ltd Protection Status

IBM Mainframe Topics