COPY Command
COPY Command
The COPY command is used to copy the contents of one or more datasets to another dataset or to a sequential file.
Syntax -
COPY FROM(source-dataset) TO(target-dataset) [options]
Where -
- source-dataset is the name of the source dataset.
- target-dataset is the name of the target dataset.
- options are the optional parameters that you can use to customize the printing.
Examples -
Scenario1 - Copy data from one PDS to another.
COPY FROM('MATEPK.TSO.TESTPDS') TO('MATEPK.TSO.TESTPDS1')
This would copy MATEPK.TSO.TESTPDS members to MATEPK.TSO.TESTPDS1.