September 2007
Newsletter Page 2

Modified October 2008

IOFTech    Maintenance   Release8G       Newsletters    Doc    FAQ    Contacts    Home    Webmaster

IOFSEND SYSIN Parameters

The optional SYSIN data set can be used to specify additional parameters to IOFSEND.

 


 

Introduction

Optional fix T8C9064 adds significant new function to IOFSEND.  This fix can be applied whether or not IOFSEND was previously installed on a system.

By adding an optional SYSIN DD statement to the IOFSEND procedure you can:

  • Specify FTP parameters
  • Specify a long list of TO addresses
  • Specify CC and BCC email addresses
  • Select specific sysout data sets to include in the attachment
  • Specify an alternate subject line or message text
  • Specify specialized parameters to XMITIP
  • Cause the FTP or Email output to be zipped

Any parameter specified on the EXEC statement will override that same parameter in the SYSIN file.

Each record in the SYSIN file represents a single keyword parameter statement, with the keyword beginning in column 1.  Leave column 1 blank to continue the previous statement.  Specify “*” in column 1 to insert a comment record.

Keyword Parameters

 

Keyword

Description

TO

One or more TO email addresses (Required either in SYSIN or in EXEC parameter in order to send email.  Not required to send via FTP)

FROM

From email address.  Not required to send via FTP.

DATA

The DATA statement defines which of the jobs sysout data sets will be included in the attachment or FTP.  By default, no sysout data sets are included,

ALL  - Include all sysout data sets in the attachment or FTP.

JESDS – Include JES2 log, JCL and messages data sets in the attachment or FTP.

INPUT – Include INPUT data set in the Job Summary.  Input data sets must be included in the Job Summary in order to be eligible to be selected with a DATA statement.

Select specific sysout data sets to be included in the attachment or FTP by specifying combinations of step, procstep, ddname.  As an alternative,  specify the dskey of the data set.  Scroll right max on the IOF Job Summary to see the data set dskey.

STEP(stepname) PRSTEP(prsname)  DDNAME(ddname)

DSKEY(dskey)

Examples:

DATA  STEP(MONTHLY)   DDNAME(REPORT)

DATA  DSKEY(107)

DATA  DDNAME(SYSPRINT)

data step(weekly)  prstep(reports)  ddname(status)

EXCLUDE

Any IOF Job Summary EXCLUDE statement to remove data sets from the current list of data sets.  Note that the IOF EXCLUDE statement removes matching data sets from the Job Summary and prevents inclusion in the attached file.

Examples:

EXCLUDE  DDNAME  EQ  SYSUDUMP

EXCLUDE  RECORDS GT 99999

NOSUMMARY

Do not include the IOF Job Summary in the attachment.  Changes default attachment format from HTML to TXT.

CC

One or more Copy email addresses

BCC

One or more BCC email addresses

SUBJECT

Email subject.  If  specified the default subject will be overridden.  The following variables can be used in the subject:

 

&JOBNAME

Jobname of the job

&JOBID

Jobid of the job

&NODE

Node name where job ran

&SYSID

System id where job ran

&RAN

Date and time job ran

&RESULT

Job result, condition codes and abends

MSGT

Email message text.  If specified the default message is overridden.  The SUBJECT variables are also available for the message text.

MSGDSN

Email message DSNAME.  If specified, the default message is overridden by the text in the specified data set.

MSGDD

Email message DDNAME.  If specified, the default message is overridden by the text in the specified data set.

FORMAT

TXT, HTML, ASA…  (XMITIP supported formats). 

Default value is HTML, which cannot be changed unless NOSUMMARY is specified.   When NOSUMMARY is specified the default format becomes TXT.

IMPORTANCE

Email importance value, LOW, NORMAL or HIGH

NOSPOOF

No spoof message will be added to the message

REPLYTO

Reply to email address

RECEIPT

Receipt email address

PRIORITY

Message priority, NON-URGENT, NORMAL, URGENT

ZIP

Compress the attachment or FTP using the ZIP program supported by XMITIP at the site.

ZIPMETHOD

Method of compression, see XMITIP

ZIPPASS

Zip password, see XMITIP

FTP

FTP address.  The FTP command, if present, will be followed by additional FTP commands.  FTP commands must appear last in SYSIN.  Everything after the FTP command is queued to z/OS FTP.

Several variables can be included in FTP commands as operands and will be substituted with the job being processed values.  Variables are:

&JOBFILE

The input file containing the job to be transmitted.  This variable can be used as the first operand in the FTP PUT command.
 

&JOBNAME

The name of the job being processed.
 

&JOBID

The JES2 jobid of the job being processed.
 

&RAN

The timestamp of when this step was run in the form  yyyy.mm.dd@hh.mm.
 

&NODE

Node name where job ran
 

&SYSID

JES2 system id where job ran
 

&RESULT

The return code/abend code of the job
 

&DEST

The destination of the job.

 

   

 

SENDMAIL  SYSIN Examples

Example 1

Send the IOF Job Summary and all sysout data sets via FTP in zip format. Create a JOBNAME directory at the FTP site if it does not already exist.  Save the job in the JOBNAME directory with file name of  RAN.JOBID.NODE.SYSID.DEST.ZIP which are variables based on when and where the job ran.  Note that there are no COND or IF parameters specified, so this step will run only if all previous steps in the job complete with a zero return code.

// EXEC  IOFSEND                            
//SYSIN  DD *                                     
ZIP                                               
DATA  ALL                                         
FTP ftp.mysite.archive.net                        
mypassword       (or other logon parameters) 
cd jobarch                                        
mkdir &jobname                                    
cd &jobname                                       
binary                                            
put &jobfile &ran.&jobid.&node.&sysid.&dest.zip   
quit                                              
/*                                                
				

Example 2

Send the IOF Job Summary, JES2 data sets and all SYSPRINT data sets via email in zip format only when the job abends or gets a non-zero return code.  Also send copies to 2 additional users. Use the default email subject and message text.

//   IF   (ABEND OR RC GT 0) THEN			
//   EXEC  IOFSEND                            
//SYSIN  DD *
TO    kjrodi32@bsnet.com
CC    operator@ccnet.net
      prodctl@ccnet.net
FROM  system@ccnet.net                                     
DATA  JESDS
DATA  DDNAME(SYSPRINT)
ZIP
/*
//    ENDIF                                               
				

Example 3

Send only the REPORT data set from the MONTHLY step to several users when the job runs with no errors.

			
//   EXEC  IOFSEND                            
//SYSIN  DD *
TO    salesmgr@widgets.com,sales44@widgets.com,
      sales45@widgets.com
CC    reg1.salesmgr@widgets.com,reg2.salesmgr@widgets.com,
      reg3.salesmgr@widgets.com,reg4.salesmgr@widgetslcom,reg5.salesmgr@widgets.com,
      reg6,salesmgr@widgets.com
FROM  batchjob@widgets.com
NOSUMMARY                                     
DATA  STEP(MONTHLY)  DDNAME(REPORT)
/*
                                            
				

 

 

Triangle Systems, Inc. PO Box 12752, Research Triangle Park, NC 27709
Email IOFTech@Triangle-Systems.Com

IOFTech    Maintenance   Release8G       Newsletters    Doc    FAQ    Contacts    Home    Webmaster

 

Return to September 2007 IOF Newsletter.