Mainframes 360
The one stop destination for System Z professionals

Thursday, June 25, 2009

Basics of JCL Simplified

Q. What is a Job?


JOB(Batch JOB) is written to run a PROC.
Q. What is JCL ?
You need to tell the MVS Mainframe, which PROC to run, what is the input dataset, where the output dataset is stored, at the outset, right at the beginning. Hence, you must write these specifications about a JOB, before submitting the JOB to the MVS in batch mode.

A JOB is written in JOB Control Language(JCL). JCL is just like any other programming language, it tells the MVS about the Batch Job. It tells the MVS, what datasets will be needed to run the JOB, request hardware devices etc. As most books quote, JCL forms the crucial link between the application program and MVS OS. You introduce a Batch JOB to the MVS OS, using JCL.
Q. What is the basic JCL Format?

Every JCL statement has the following format.

Every statement in JCL has a name, by which it can be referred to. Every JCL statement should begin with two forward slashes //. Next, comes the operation field. Here, you specify the type of operation e.g. JOB, EXEC and DD. Then, you write the list of operands separated by commas. Finally, you have a comments field.

Q. Are there any JCL Coding Guidelines?
Yes, just as every programming language like C has its own grammar, its own syntax, JCL also has its own syntax.
1. Every JCL Statement begins with two forward slashes //.
2. JCL is case-sensitive(we always use the upper-case)
3. The name field is optional.
4. The name field must begin in column 3.
5. The operation field must begin on or before column 16.
6. The operands can continue upto column 71.
7. If the operands overflow onto the next line, they must start between columns 4-16.

As you might deduce from the above rules, JCL lays down stringent guidelines about the alignment of different fields. To check if you have written valid JCL, you can always type HI JCL on the screen, to highlight the different fields.

To many people who are thrown to work at a mainframe computer on their first job, they feel lost. Mainframe people seem to speak a completely different language and that doesn't make life easy. What's more, the books and manuals are incredibly hard to comprehend.

"What on earth is a Mainframe?" is an absolute beginner's guide to mainframe computers. We'll introduce you to the hardware and peripherals. We'll talk about the operating system, the software installed on a mainframe. We'll also talk about the different people who work on a mainframe. In a nutshell, we'll de-mystify the mainframe.

Readers based in India, can buy the e-book for Rs. 50 only or the print book. International readers based in the US and other countries can click here to purchase the e-book.