TSO Applications | Using Workgrouping |
The JCL support in Mainframe Express is a batch environment emulating JCL. Use it to include a JCL jobstream in a Mainframe Express project. You can build your JCL and compile your application, edit it, and debug it in an JCL environment on your PC.
You need to have read the chapter Start Here for the Tutorials and worked through the first session, Using Mainframe Express, before you do this session.
In this session, we assume you are familiar with JCL on a mainframe.
This session takes you through maintaining and running an application using JCL on your PC. It shows you how to create and build a project that includes a JCL file.
The demo application used in this session is a simple application that you might have downloaded from a mainframe. It simply copies data from an input file to the screen. In this session, you get it working on your PC.
The chapter Using Mainframe Express introduced you briefly to running a JCL jobstream. This session goes deeper into the use of the JCL support. You see how to add a procedure to a procedure library and look at the spool and log files.
You have already seen how to create a project for an application that uses JCL in the chapter Using Mainframe Express. To save you creating the project used in this session, we supply the project jcldemo.mvp.
The full path is \mfuser\projects\gsdemo\jcldemo\jcldemo.mvp. If you use Open on the File menu, you need the Files of Type field on the Open dialog box set to Project files (*.mvp) to see this file.
You'll see the .jcl and .cbl files in the Files View. If you click the Catalog tab you'll see the input file JCLDEMO.MFDEMO.DATA in the Catalog View.
In this session you:
First you need to add a cataloged procedure to the procedure library SYS1.PROCLIB. A procedure library is a partitioned data set (PDS) and the procedures are members.
The Catalog View changes to show the members of SYS1.PROCLIB. There is just one, MFDEMOUT.
A source view window appears showing the source of the procedure mfdemout.prc.
This displays the list of data sets in the catalog again.
To build the project:
As you saw in the chapter Using Mainframe Express, the correct compiler is automatically called for each source file - in this case, for the COBOL and JCL files.
The build finishes with "Build finished with no errors".
As on a mainframe, a job produces at least one spool file, and the one spool file you always get is a JCL listing showing data allocations and so on. The Project window contains a view called the Spool View, where you can view these. You now view the spool file produced by Mainframe Express, showing what happened to the build job.
The spool file from the build job is shown in the Spool View.
A source view window appears showing the contents of the spool file. Notice that the cataloged procedure, MFDEMOUT, has been included in the jobstream.
The //PROC
and //JOBLIB
statements are
used when this job is run on a mainframe in another session. They are
ignored when the job is run on the PC.
To run the jobstream:
The Application Output window appears and the application runs. You can see its progress in the Application Output window. If you view the SYSOUT file on the Spool view you can see that five records have been written from SYSUT1 to the temporary file SYSUT2.
Most JCL jobs that are run on the PC write to a file called the system log, which is equivalent to the system console on the mainframe. Messages that would go to the system console on the mainframe, go to the system log on the PC. This file is initially created by the first job that writes to it.
To view the system log:
A source view window appears showing the contents of the system log.
The system log can also be seen in the Catalog View. It is called MFMVS.SYSLOG.
Note: This session contains no section on debugging a JCL jobstream, because the chapter Using Mainframe Express covered that.
Close the project. If you want to take a break before going on to the next session, you can close Mainframe Express.
Return to the Tutorials Map in the chapter Start Here for the Tutorials and choose which session to go on to next, depending on your interests.
Copyright © 1999 MERANT International Limited. All rights reserved.
This document and the proprietary marks and names
used herein are protected by international law.
TSO Applications | Using Workgrouping |