>>-+---------+-------------------------------------------------><
'-REPlace-'
REPLACE
specifies that DFSMSdss is to search the target volumes
for usable preallocated data sets. If a usable preallocated target
data set is found, it is replaced with the source data set. If no
preallocated target is found, DFSMSdss attempts to allocate a data
set.
DFSMSdss searches for preallocated data sets as follows:
- For SMS-managed data sets, DFSMSdss first searches in the
standard
order of search for a catalog entry for the data set.
- For
VSAM data sets that are not SMS-managed, DFSMSdss searches
the output volumes for preallocated data sets. If no output volumes
are specified, DFSMSdss searches for a catalog entry for the data
set.
- For Non-VSAM data sets that are not SMS-managed, DFSMSdss
searches
the output volumes for preallocated data sets. If no output volumes
are specified, DFSMSdss searches for a catalog entry for the data
set.
- If no preallocated target is found, DFSMSdss attempts
to allocate
a data set. DFSMSdss invokes the ACS routines to determine if the
data set should be SMS managed. If it should be SMS managed, then
allocation is done according to the SMS constructs. If the data set
should not be SMS managed, the output volumes specified are used.
If allocation is successful, the data set is copied.
Note: - If REPLACE is specified with the COPY command:
- The SMS constructs already associated with the preallocated
target
data set remain the same
- The CA Reclaim attribute already
associated with
the preallocated target data set remains the same.
- CATALOG
and RECATALOG are ignored for preallocated data sets.
- If the
source data set is an extended-addressable VSAM data set,
then the target must also be an extended-addressable VSAM data set.
- The target data set name must match the source data set name.
REPLACEUnconditional must be specified to replace a target data set
that has a name matching the rename criteria.
- The REPLACE
and REPLACEUnconditional keywords can not be specified
together.
- If the RENAMEU keyword is specified in conjunction
with the REPLACE
keyword, only one of the keywords take effect for any particular data
set. The RENAMEU keyword takes precedence over the REPLACE keyword.
If a source data set name matches the RENAMEU criteria, then rename
processing will be performed and replace processing will not be performed.
If a preallocated target data set exists with the new name as chosen
by the rename criteria, then the copy fails even if the REPLACE keyword
was specified. If you want to replace a preallocated target with the
new name, specify the REPLACEUNCONDITIONAL keyword. If a source data
set name does not match the rename criteria and a preallocated target
data set with the source name exists, the preallocated target data
set is replaced.
- If the source data set is a large format
sequential data set,
but the preallocated target is not a large format sequential data
set, the preallocated target data set will be used and turned into
a large format sequential data set as long as it has enough allocated
space for the source data set.