TSO-ISPF JCL COBOL VSAM DB2 CICS IMS-DB Tools Articles Forum Quiz Interview Q&A

JCL - IEBGENER Utility


The IEBGENER utility is a copy program. One of its many uses is to copy a sequential data set, a member of a partitioned data set (PDS) or PDSE.

IEBGENER also can filter data, change a data set's logical record length (LRECL) and block size (BLKSIZE), and generate records.

The most common use is to simply copy data sets. A typical job looks like below example,


Example 1: COPY PS dataset.

//JOBIBMKS JOB (123),'IBMMAINFRAMER',CLASS=C,MSGCLASS=S,MSGLEVEL=(1,1),
//       NOTIFY=&SYSUID
//STEP001  EXEC PGM=IEBGENER
//SYSIN    DD DUMMY
//SYSPRINT DD SYSOUT=X
//SYSUT1   DD DSN=userid.SEQ.DATA,DISP=SHR
//SYSUT2   DD DSN=userid.COPY.DATA,
//        DISP=(NEW,CATLG),UNIT=3390,
//        VOL=SER=WORK02,SPACE=(TRK,3,3)),

IEBGENER requires four data definition (DD) statements with the DD names shown in the example,

Explanation:

  • The SYSIN DD statement is used to read control parameters; for simple uses, no control parameters are needed and a DD DUMMY can be used.

  • The SYSPRINT statement is for messages from IEBGENER.

  • The SYSUT1 statement is for input and the SYSUT2 statement is for output. This example reads an existing data set and copies it to a new data set.



If you have any doubts or queries related to this chapter, get them clarified from our Mainframe experts on ibmmainframer Community!

Are you looking for Job Change? Job Portal