Create and Copy a VSAM ESDS Data Set (z/OS to z/OS)

This COPY statement transmits a VSAM ESDS file to a new VSAM ESDS at another site. The RECORG parameter specifies that the target VSAM data set is an ESDS. The LRECL parameter specifies the maximum length of a record in the VSAM data set.

COPY  FROM  (DSN=VSAM.ESDS.SOURCE)  -
      TO    (DSN=VSAM.ESDS.DEST     -
             DISP=(NEW,CATLG)       -
             RECORG=ES              -
             LRECL=128              -
             STORCLAS=SCLASS1       -
             MGMTCLAS=MCLASS1)