Appendix: Editing JCL Templates in OS390 for COBOL and SQR

This appendix provides an overview of JCL templates and discusses how to:

Click to jump to parent topicUnderstanding JCL Templates

The PeopleSoft Server Transfer program creates a directory $PS_HOME/appserv/prcs/shelljcl in the OS390 UNIX Services to store a master copy of the shell JCL templates. When you create a PeopleSoft Process Scheduler Server configuration, it copies the shell JCL templates into the $PS_HOME/appserv/prcs/<database name>/shelljcl directory. This includes all of the JCLs used for running COBOL and SQR through PeopleSoft Process Scheduler.

The following table lists the shell JCL templates used in PeopleSoft Process Scheduler:

JCL

Description

SHELCBL.JCT

Invoked by PeopleSoft Process Scheduler when a user requests to run a COBOL program.

SHELSQRF.JCT

Invoked by PeopleSoft Process Scheduler when a user requests to run an SQR program and indicates on the Process Scheduler page to route the output to a file, the web, or an email message.

SHELSQRP.JCT

Invoked by PeopleSoft Process Scheduler when a user requests to run an SQR program and indicates on the Process Scheduler page to route the output to a printer.

SHELSQROUTP.JCT

Used in conjunction with SHELSQRP.JCT or SHELSQRF.JCT. This template contains the file definition for creating a partitioned dataset for SQR report files. PeopleSoft Process Scheduler uses this template when the SQR output format is:

  • Acrobat Reader (PDF).

  • PostScript (PS).

  • Line Printer (LP).

  • HP format.

SHELSQROUTS.JCT

Used in conjunction with SHELSQRP.JCT or SHELSQRF.JCT. This template contains the file definition for creating a sequential dataset for SQR report files. PeopleSoft Process Scheduler uses this template when the SQR output format is HTM or SPF.

You must modify these shell JCL templates to comply with your site standards.

PSADMIN has an Edit a Shell JCL template to enable you to edit a JCL using the VI editor. If you are not familiar with the VI editor and prefer to edit the JCLs using the ISPF editor, you can use the TSO oedit command in the TSO session. The IBM TSO oedit command enables you to modify any files residing in USS from a TSO session. You can edit any of the shell JCL templates found in $PS_HOME/appserv/prcs/<database name>/shelljcl directory as shown in the following example. Please consult your OS390 system administrator for using the oedit command at your site.

Example of editing shell JCL templates

Click to jump to parent topicCustomizing the PeopleSoft Process Scheduler Shell JCL Template

All of the PeopleSoft Process Scheduler shell JCLs use meta-strings to pass data stored in the database or PeopleSoft Process Scheduler configuration files. PeopleSoft Process Scheduler uses meta-strings to generate the JCL based on one of these sources:

A good example of data that can be passed includes job account and job name. Enter the values of some of these variables by selecting PeopleTools, Security, Permissions & Roles, Permission Lists.

The shell JCL templates are tunable and should be changed according to your site-specific standards. The following table identifies the meta-strings that you can use in a shell JCL template.

If you create a new JCL template, be aware that:

Meta-String

Description

%JOBNAME%

Specifies the value entered in the OS390 Job Controls Name field on the Process Profile Permission page for the permission lists specified as the user ID’s process profile. The process profile for a user ID can be set using the User Profiles page in the Security component.

%JOBACCT%

Specifies the value entered in the OS390 Job Controls Account field on the Process Profile Permission page.

%OUTDEST%

Specifies the output destination based on the value entered in the Server Destinations File or Printer field on the Process Profile Permission page.

%SFX%

Identifies a one-character code issued by PeopleSoft Process Scheduler. The system randomly assigns a value from A to Z.

%OPRID%

Identifies the user ID used to submit the request from PeopleSoft Process Scheduler.

%PRCSLOGFILE%

Identifies the name of the log file that PeopleSoft Process Scheduler used to redirect all data written to output for PeopleSoft Application Engine or SYSOUT in COBOL or SQR

%PRCSLOGDIR%

Identifies the directory to which all log files or reports are written in USS for a process.

%ACCESSID%

Identifies the access ID that is assigned for a user ID defined in PSOPRDEFN.

%INSTANCE%

Identifies the process instance number that is assigned to a process request.

%RUNID%

Identifies the run control ID used to submit the process request.

%OWNERID%

Identifies the owner ID for the PeopleSoft database.

%PRCSNAME%

Identifies the program name, as defined on the Process Definition page.

%DB2SUB%

Identifies the name of the DB2 subsystem specified in the DB2 Sub-System parameter in the OS390 section in the PeopleSoft Process Scheduler configuration file.

%PERFSTAT%

Sets the Performance Statistic option in the COBOL shell JCL. This is set to Y when the bit value of 128 is assigned to the TraceSQL parameter in the Trace section in the PeopleSoft Process Scheduler configuration file.

%DYNEXPLN%

Sets the Dynamic Explain option in the COBOL shell JCL. This is set to Y when the bit value of 256 is assigned to the TraceSQL parameter in the Trace section in the PeopleSoft Process Scheduler configuration file. Bit value 256 will also turn on Performance Statistics in the COBOL shell JCL (%PERFSTAT% will be set to Y) as is required to run the Dynamic Explain.

%PARALLEL%

Sets the Dynamic Explain option in the COBOL shell JCL. This is based on the Enable Parallel Processing parameter in the OS390 section in the PeopleSoft Process Scheduler configuration file.

"%TSOPLAN%

Indicates the DB2 plan name subsystem specified in the Plan name for PTPSQLRT with TSO parameter in the OS390 section in the PeopleSoft Process Scheduler configuration file.

%PSHLQ%

Indicates the high-level qualifier of the PeopleSoft dataset specified in the High Level Qualifier for Datasets parameter in the OS390 section of the PeopleSoft Process Scheduler configuration file.

%SQRINI%

Identifies the initialization file used by the SQR process. This meta-string is used exclusively for SQR.

Following is a sample job control card in one of the shell JCLs:

//%JOBNAME%%SFX% JOB %JOBACCT%,'PS-PRCS ',CLASS=E,MSGCLASS=X,

// NOTIFY=%OPRID%

If you do not use meta-strings, you can also update the job cards to remove these variables and replace them with actual values.

In the SHELL JCL for SQR, OUTNODE denotes either an OS390 partitioned dataset (PDS) or a sequential dataset. The PDS is a requirement for SQR output. If the SQR report XRFPANEL is directed to file output, the following substitution occurs:

In SHELSQRF.JCT, change// OUTNODE='%OUTDEST%' to // OUTNODE='HR.H800RAB', .

If an SQR process is directed to print, the following substitutions occur:

// OUTNODE='DEST=U3', OPTIONAL:USER-DEF OUTPUT . .

//*********************************************************************

//* Main portion of JCL Shell *

//*********************************************************************

..

//SQROUTP DD SYSOUT=*,DEST=U3

Click to jump to top of pageClick to jump to parent topicOS390 Job Controls

OS390 job controls specify the OS390 job name to assign to each process that is submitted. This value can be up to seven characters. Do not use lowercase letters or quotation marks. If you included the %SFX% meta-string as part of the job name, PeopleSoft Process Scheduler appends a one-character alphabetical suffix to this name (A through Z, chosen randomly) before the job submission.

For example, if you entered USRMVS1, the assigned job name becomes USRMVS1A through USRMVS1Z. After you enter the OS390 job name, enter the job account number that you used in the installation. Specify an account code to be inserted as the JCL accounting code.

Click to jump to parent topicRunning PeopleSoft Process Scheduler or Application Engine From a JCL in OS390

PeopleSoft Process Scheduler is customarily started and stopped from a JCL sample. JCLs are provided to accomplish this task. An Application Engine program must also be run from a JCL in some business cases. Any PeopleSoft executable residing in the UNIX System Services (USS) can be invoked from a JCL using the IBM BPXBATCH utility.

In the high-level qualifier where PeopleSoft is installed in OS390, a partitioned dataset (HLQ.JCLLIB) contains the following JCL:

The following table identifies the meta-strings to use, in the order specified in a shell JCL template, for USS scheduler to pass COBOL parameters so that it can, in turn, call Application Engine:

Meta-String

Description

%PS_HOME%

Path of PeopleSoft home directory

%PS_SERVDIR%

Full path of the server directory, for example, $PS_HOME/appserv/prcs/PT840GA.

%PS_SERVERCFG%

Full path of the psprcs configuration file, for example, $PS_SERVDIR/psprcs.cfg.

%PS_CONFIG%

Full path of the psprcs.sh file, for example, $PS_HOME/psconfig.sh.

%HFS_USERID%

Login ID (userID). Same authorities as the userID used for installation, or the userID that started Process Scheduler.

%JOBNAME%

Specifies the value entered in the OS390 Job Controls Name field on the Process Profile Permission page for the permission lists specified as the user ID’s process profile. The process profile for a user ID can be set using the User Profiles page in the Security component.

%REGION_SIZE%

Region size. The Default is −1.

%CPU_TIME%

Maximum CPU time this Application Engine process is allowed to use. The default is 1000. This matches the default value for MAXCPUTIME variable of BPXPRMxx member of the SYS1.PARMLIB.

Click to jump to parent topicLimitations of Process Scheduler Server

In the USS environment, Process Scheduler submits COBOL and SQR by means of a JCL. Although Process Scheduler can capture the job name of a JCL, it is incapable of capturing the job ID assigned by TSO. Consequently, Process Scheduler does not have the ability to query or manage a JCL that has been submitted to the TSO environment.

As a result, Process Scheduler does not have the ability to cancel a JCL job when a user requests to cancel an SQR or COBOL process using the Process Monitor page. While Process Scheduler does not kill the JCL associated with the process, it does make the slot available for any other queued SQR or COBOL processes. Therefore, you must manually cancel the JCL from a TSO session.

Note. This limitation does not apply to Application Engine requests initiated from z/OS. The executable of an Application Engine is terminated when a user cancels the submitted request from the Process Monitor page.