File manager batch using a Rexx procedure
Posted: Wed Aug 24, 2016 1:42 pm
The trouble for me, based on what I'm trying to do, is that I can't find any examples related to what I'm trying to do (and, yes, I could be going at it the wrong way, but that's simply due to my fumbling in the dark).
Okay, here's what I'm trying to do. I want to run FM in batch so that it produces my output for the first x columns only. Neither do I want any IBM boiler plate at the top of the file. Here's an example of what I've tried
The Rexx code looks like this (I'm conversant with Rexx). Remember, the code here is my fumbling, trying to understand what ends up where.
These are my results
The quote above can be divided into the following "groups":-
Record 00402147391 (the say from my Rexx)
REC 10 DATA 165 (something printed from FM ????)
IBM File Manager for z/OS (the IBM boiler plate that I don't want)
Length P348-TYP-POST-HAFO P348-PERS-ORG-SHB-NR-SEKEL (to the end, the actual FM TABL formatting of the input file).
What I don't get from the manual (feel free to point me at the page) is how I define an output file to receive the data starting with
Length P348-TYP-POST-HAFO P348-PERS-ORG-SHB-NR-SEKEL as well as how I can "chop" the output results (the template has a large filler field at the back-end which is also printed, and that I DON'T want in the output).
So basically, I want to run the TABL command in batch using a Rexx procedure (if needed) so that only the first 100 columns are printed.
Okay, here's what I'm trying to do. I want to run FM in batch so that it produces my output for the first x columns only. Neither do I want any IBM boiler plate at the top of the file. Here's an example of what I've tried
Code: Select all
//EXAMPLE EXEC FILEMNGR
//FMNEXEC DD DISP=SHR,DSN=MISI01.PRIVATE.CODE
//SYSPRINT DD SYSOUT=*
//DDIN DD DISP=SHR,DSN=MISI01.FOHA.Q265001
//FMOUT DD DSN=MISI01.FMAN.TEST,DISP=(,CATLG),
// RECFM=FB,LRECL=132
//SYSIN DD *
ÅÅFILEM DSP INPUT=DDIN,MEMBER=BATCH,PROC=MSFILEMN
ÅÅFILEM DSP FORMAT=TABL,
ÅÅFILEM TCIN=xxx.yyy.zzz(HAFOP348)
Code: Select all
rname = 'MSFILENM'
say "Record "substr(inrec,14,11)' '
record.0 = 1
record.1 = substr(inrec,14,11)
address TSO "execio 1 diskw FMOUT (stem record."
Code: Select all
Record 00402147391
REC 10 DATA 165 01333214191560040214739120160822SE0000709
Record 00000000000
IBM File Manager for z/OS
REC 11 DATA 165 01333214191560000000000020160822SE0000500
Record 00402147391
REC 12 DATA 165 01333214191560040214739120160822SE0001192
FMNBE082 12 record(s) printed
ÅÅFILEM DSP FORMAT=TABL,
ÅÅFILEM TCIN=SHB.PR2.COPY(HAFOP348)
IBM File Manager for z/OS
* * * * Device 350A, 3390, VOLSER=SMS109 Data Set
* * DSORG PS, RECFM FB, LRECL 165 BLKSIZE 27885
Length P348-TYP-POST-HAFO P348-PERS-ORG-SHB-NR-SEKEL P348-AVKASTNKTONR
ZD 1:2 ZD 3:11 ZD 14:11
<-> <---+----1-> <---+----1->
000165 1 33321419123 0
000165 1 33321419131 402147731
000165 1 33321419131 402147731
Record 00402147391 (the say from my Rexx)
REC 10 DATA 165 (something printed from FM ????)
IBM File Manager for z/OS (the IBM boiler plate that I don't want)
Length P348-TYP-POST-HAFO P348-PERS-ORG-SHB-NR-SEKEL (to the end, the actual FM TABL formatting of the input file).
What I don't get from the manual (feel free to point me at the page) is how I define an output file to receive the data starting with
Length P348-TYP-POST-HAFO P348-PERS-ORG-SHB-NR-SEKEL as well as how I can "chop" the output results (the template has a large filler field at the back-end which is also printed, and that I DON'T want in the output).
So basically, I want to run the TABL command in batch using a Rexx procedure (if needed) so that only the first 100 columns are printed.