Sample - BankDemo JES

The BankDemo JES sample builds upon the BANKDEMO CICS application and demonstrates a JCL job that extracts, sorts and prints a customer statement from the BankDemo database.

This sample uses resources stored on a local disk based file system rather than database-hosted.

Note: This sample assumes that you have followed and completed the installation verification process described here Installing and Verifying the Software and you have successfully started and run the JCLDEMO region and have successfully submitted a test JCL.

The BankDemo JES sample files are in%PUBLIC%\Documents\Micro Focus\Enterprise Developer\samples\Mainframe\JCL\DotNet\BankDemo.

Follow steps 1 and 2 of the CICS BankDemo sample to create the database and compile the application. Stop at the end of step 2, and do not deploy to the database.

Then complete the following steps:
  1. Configure an XA resource definition for the bankdemo database as described in Configuring XA resources
    1. An XA resource definition is used to tell the region how to connect to the database.
    2. Ensure that the application plan field in the XA resource definition is set correctly (BANKDEMO in this case).
    3. Call the XA resource "bank" and associate it with the JESBANK region.
  2. Create the JESBANK region.

    These steps are not detailed, as most of the process has been previously described in other tutorials.

    1. Open the Enterprise Server for .NET Administration UI.
      1. Create a new JES Region called JESBANK, hosted in the (local) database.
      2. Select the region startup called REGION_JESBANK.CONFIG file from the sample directory
      3. If you don't want to use the default catalog and data file locations, adjust them.
    2. Create a listener endpoint for the JESBANK region on a suitable mfbinp port.
    3. Start the region.
    4. Start the listener.
  3. Submit the JCL job entitled DEFBANK.JCL into the JESBANK region.
    1. This will create and initialize some required data sets in the catalog.
  4. Submit the JCL job entitled ZBNKSTMNT.JCL into the JESBANK region.
    1. This will perform three steps: extract, sort, and print.
    2. Examine the spool output at the end of the job to see the result.
Note:

The ZBNKSTMNT job runs three procs stored in the MF.PROCLIB PDS dataset:

  • YBNKEXTS - extracts the data from the database.

    It uses TSO syntax in a control card, KBNKTSO2.TXT stored in the MFI01.MFIDEMO.CTLCARDS PDS.

  • YBNKSRT1 - sorts the retrieved data.

    It uses sort parameters in a control card , KBNKSRT1.TXT stored in the MFIDEMO.MFI01.CTLCARDS PDS.

  • YBNKPRT1 - prints the statement.

    It invokes the COBOL program ZBNKPRT1 included in the BankDemo CICS sample.