The PRINTOFF TSO command allows you to print the contents of a sequential dataset or partitioned dataset members. The output from the command is released to JES2 immediately for processing, so you can use the command to produce output to an attached (to Hercules) printer while you remain logged onto your TSO session.
There are several versions of the PRINTOFF command available, depending upon which version of the CBT tape you are using. I chose the one located in File #325 of the current version, which includes this comment:
PRINTOFF - The widely modified IPO supplied TSO command to print a (01/87) dataset, with yet more functions added. After researching all versions on the CBT tape, Wells Fargo created this version from source from four separate files. We believe this contains all features currently available from all sources.
There is no jobstream provided to assemble PRINTOFF, but the assembler source does include the help text, so I added the JCL to assemble and link-edit PRINTOFF into SYS2.CMDLIB and place the help text into SYS2.HELP with aliases corresponding to the aliases built for the command. The source from the CBT tape will receive an undefined symbol during assembly:
STMT ERROR CODE MESSAGE6751 IFO188 DALUSRID IS AN UNDEFINED SYMBOLNUMBER OF STATEMENTS FLAGGED IN THIS ASSEMBLY = 1 HIGHEST SEVERITY WAS 8
This is caused by an EQUate that is missing from the MVS 3.8j version of the system macro IEFZB4D2. I have coded an EQU for the missing symbol in the source, using a later version of the system macro for reference to eliminate the assembly error.
The jobstream - printof$.jcl - is contained in the archive printoff.tgz [MD5: e85a97357010bfa916c26a8c56bf176d]. Download the archive and extract the jobstream (WinZip on Windows/?? or tar on Linux). Submit the jobstream to assemble and link the single load module for PRINTOFF into SYS2.CMDLIB and copy the help text into SYS2.HELP. If you don't have SYS2.CMDLIB defined, you will need to modify the jobstream to specify a different target load library. Also if you do not have SYS2.HELP defined, you may modify the jobstream to place the help information into SYS1.HELP.
PRINTOFF has many options, most of which you will never need. In fact, most of the time you will simply specify a dataset (or dataset list) and a class operand. The help text provided is thorough, and explains all options well:
The PRINTOFF command creates a printed copy of data sets through foreground copying to SYSOUT. The command prints datasets which are sequential or partitioned, blocked or unblocked, with fixed, variable, or undefined length records of any length up to 32,760. Syntax - PRINTOFF (dslist)/* DDNAME(ddname)/FILE(ddname) UNIT(unit-type) VOLUME(volser) NOMESSAGES/NOMSGS CLASS(class) DEST(destination) COPIES(nnn) HOLD/NOHOLD LIST/NOLIST PRINT/NOPRINT FORMS(form) FCB(fcb) TRAIN(image)/UCS(image) HEADING/NOHEADING CAPS/ASIS/FOLD/NOFOLD NOCC/SINGLESPACE/SS/DOUBLESPACE/DS ASA LINELENGTH(nnn)/LL(nnn) PAGELENGTH(nnn)/PL(nnn) BURST/NOBURST FLASH(flash-name) CHARS(charset-name(s)) PROG(progname) UDKFONT(font-name) Required -- dslist or * if DDNAME(...) Aliases -- PRINTO, PO Defaults -- CLASS(A), COPIES(1), NOHOLD, LIST, PRINT, FORM($TST), HEADING, ASIS, LINELENGTH(132), PAGELENGTH(60), NOBURST, SINGLESPACE if PAGELENGTH(...) or if input RECFM not A/M Operands - DSLIST - Data set list contains the names of data sets to be printed or punched. The names should follow TSO convention, in quotes if the primary index differs from your profile prefix, or without quotes and with the primary index omitted if it is the same as your profile prefix. Enclosing parenthesis are required if there is more than one name in the list. If DDNAME(...) is specified, the dslist must end with an asterisk (or contain only an asterisk) as a place holder. ASA - Output is to be printed using input data column 1 as ASA carriage control characters even though the DCB record format does not specify RECFM=..A ASIS - Output is not to be converted to upper case prior to printing. (It is left as it is.) NOFOLD is an alias for ASIS. BURST - Output is to be trimmed and burst. ===> VALID FOR 3800 ONLY NOBURST - Output will be printed on continuous forms. CAPS - Output is to be converted to upper case prior to printing. FOLD is an alias for CAPS. CHARS(charset-name(s)) - Character set(s) to be used to print the output. (1-4 names, each name 1-4 characters.) If more than one character set name is given, the input data should have the character set id specified in the second character of each line. OPTCD=J is assumed. See the JCL reference manual for more information. ===> VALID FOR 3800 ONLY CLASS(class) - SYSOUT class in which output is to be printed. Default is A. COPIES(nnn) - Number of copies to be printed. Default is 1. DEST(destination) - The destination to where SYSOUT is to be routed. Destination can be a JES remote line, a JES local or remote printer, or a network node and userid. Local and remote names are 1-8 characters. Network names are 3-17 characters (node.userid) with the period required as a separator. DEST(node.userid) is mutually exclusive with PROG(progname). DDNAME(ddname) - DD name of a previously allocated dataset. If DDNAME is specified, the last (or only) dataset name in dslist must be an asterisk. The DD will not be freed after being printed. FILE is an alias for DDNAME. FCB(fcb) - Forms Control Buffer to be used when the data set is printed. (1-4 character FCB name) FLASH(flashname) - The name of the forms flash overlay which is to be flashed on all output. ===> VALID FOR 3800 ONLY FORMS(form) - Form to be used when the data set is printed. Default is $TST. (1-4 character form name) HEADING - Output is to have a heading containing the data set name. NOHEADING - Output is not to have heading information. HOLD - Output is to be placed on a hold queue upon deallocation. NOHOLD - Output is not to be placed on a hold queue upon deallocation. LINELENGTH(nnn) - Number of characters on each line of printed output. (1-208 characters with a default of 132.) Input lines longer than specified linelength will be printed on multiple lines. LL(...) is an alias for LINELENGTH(...). LIST - A separate listing of member names processed is to be created and printed with the data set output. NOLIST - No list of member names is to be created. NOMESSAGES - Non-error messages are not to be written to the TSO terminal. NOMSGS is an alias of NOMESSAGES. The default is to write informational messages to the terminal before and after printing. PAGELENGTH(nnn) - Number of lines per page. (1-120 lines with a default of 60.) Carriage control in input records is ignored (even if ASA is specified) and SINGLESPACE is used. PL(...) is an alias for PAGELENGTH(...). PRINT - Members are to be printed. (Whether they are also listed is controlled by LIST/NOLIST.) NOPRINT - Members are not to be printed. (Whether they are to be listed is controlled by LIST/NOLIST.) PROG(progname) - The name of the special 'external writer' program that is to process the output. PROG(progname) is mutually exclusive with DEST(node.userid). TRAIN(image) - Print image to be used when the data set is printed. UCS is an alias for TRAIN. (1-4 character print image name) UCS(image) - Print image to be used when the data set is printed. UCS is an alias for TRAIN. (1-4 character print image name) SINGLESPACE - Output is to be single spaced. Carriage control in input data is ignored even if ASA is specified. NOCC and SS are aliases for SINGLESPACE. DOUBLESPACE - Output is to be double spaced between lines. Carriage control in input data is ignored even if ASA is specified. DS is an alias for DOUBLESPACE. (Multiple line records will not be split between pages.) UNIT(unit-type) - Unit type of the specified VOLUME(volser). UNIT is ignored if VOLUME is not also specified. UNIT is required only when the dataset is not cataloged, or when the dataset is cataloged to a different volume than the specified VOLUME and the volume cannot be accessed through your TSO default unit type. VOLUME(volser) - Volume serial of volume on which data sets to be printed are found. This volume serial will be used for all data sets specified in the data set list. UDKFONT(font-name) - Output is intended to be printed on a XEROX 2700 or 3700. PRINTOFF will insert Xerox User Defined Key (UDK) statements in the output to select the specified font. No validation is performed on the font name before it is sent to the printer, so the full font name must be specified in upper/lower case exactly as expected by the XEROX printer. (PRINTOFF uses the left brace character, {, hex C0, as the UDK. Input data containing this character will be interpreted by the printer as a Xerox command, and may produce undesired results.)
I hope that you have found my instructions useful. If you have questions that I can answer to help expand upon my explanations and examples shown here, please don't hesitate to send them to me:
This page was last updated on January 17, 2015 .