We are running CICS/TS 1.3 and the journal utility program (DFHJUP) is being used to offload the journal data....
I would like to take that data, which is offloaded to an unblocked dataset, and copy it to a fixed-blocked dataset. When I view the data from ISPF 3.4 the records viewed don't exceed 161 bytes. What is the best way to accomplish this task?
Back in the VERY old days, one used to do all this sort of thing via the IEBGENER utility. However, when I need to alter record length or otherwise do reblocking operations, I use the MVS (or VM) PIPE command. This runs quite happily natively in JCL, or the TSO Environment, and you can very easily plonk this operation inside a Rexx Exec, If you look at one of my SupportPacs (that one to do with EXCI linkage to Batch), you will see an example of how to use Pipes in a complex fashion. Here is some simple JCL which will suit: //RUN EXEC PGM=PIPE, // PARM='(SEP ;) < dd=IN ; chop 200 ; pad 200 ; > dd=OUT' //SYSPRINT DD SYSOUT=* //SYSUDUMP DD SYSOUT=* //IN DD DSN=&&IN,DISP=SHR //OUT DD DSN=&&OUT,DISP=(NEW,PASS), // UNIT=SYSDA, // SPACE=(CYL,(1,1)), // DCB=(RECFM=FB,LRECL=200,BLKSIZE=200) The reason why you need both the CHOP and the PAD is that this will ensure fixed-length records by truncating longer ones (the CHOP) and extending the shorter ones (PAD). You can put another parm on the PAD to extend with a given character (which can be specified in Hex). You can extend this technique by using other stage commands to do record selection as part of the pipe operation or get into Secondary and Tertiary streams. You may also want to use the SPECS stage command to reformat the records (the example below puts in a prefix for each output stream). In these cases, you will need to construct larger operations by using the RUNPIPE construct (this is taken from the aforementioned SupportPac). The thing to note is the use of the PIPEIN file to contain the full Pipe command to be executed and PIPEOUT to receive the output from the sequence: the JOIN * gets rid of lines from the PIPEIN file so allowing you to code the pipe with meaningful idents which are got rid of on execution (there are various size limitations around). For info, the RXDPLP stage command is a Rexx Exec, living in the //REXX library : use this functionality to do more complicated things than is permitted (or is easier ) in the Stage processing on a record-by-record basis. //RUN4 EXEC PGM=PIPE, // PARM='(SEP ; end ? ) < dd=PIPEIN ; join * ; // runpipe ; > dd=PIPEPOUT coerce' //REXX DD DSN=RHARRI1.CA1IEXEC,DISP=SHR //STEPLIB DD DSN=UTL.RHARRI1.LOAD,DISP=SHR,DCB=BLKSIZE=32760 // DD DSN=RHARRI1.CA1HLOAD,DISP=SHR // DD DSN=CICS.SDFHEXCI,DISP=SHR //SYSPRINT DD SYSOUT=* //SYSUDUMP DD SYSOUT=* //PIPEPOUT DD SYSOUT=*,DCB=(RECFM=F,LRECL=132,BLKSIZE=132) //PIPEOUT DD SYSOUT=*,DCB=(RECFM=F,LRECL=132,BLKSIZE=132) //SYSTSPRX DD SYSOUT=* //SYSTSPRT DD SYSOUT=*,DCB=(RECFM=F,LRECL=132,BLKSIZE=132) //PIPEIN DD * (SEP ; end ?) literal cemt i task ; literal RAH Rules ; ss: RXDPLP (W2) (C1) * * / notrace retain abend/; specs /1->/ 1 1-* next ; > dd=PIPEOUT coerce literal utprogb iyckrah6 word3 word4 word5 ; ss: ; specs /2->/ 1 1-* next ; > dd=PIPEOUT coerce ss: ; specs /3->/ 1 1-* next ; > dd=PIPEOUT coerce /*
Related Q&A from Robert Crawford
For better mainframe capacity planning, how do I convert CPU hours to MIPS? And is there a way to calculate the relationship between MIPS and MSUs? Continue Reading
I have two years of experience in mainframe technology, currently working as a mainframe developer. I want to change to Java technology. Continue Reading
I want to replicate DB2 from the mainframe to an AIX box since it's cheaper and the copy can be used for testing. Is this possible? Continue Reading
Have a question for an expert?
Please add a title for your question
Get answers from a TechTarget expert on whatever's puzzling you.