TOCOPY—Define the Image Copy to Use

The TOCOPY keyword specifies the image copy to which you want to recover.
cafrdb219
The TOCOPY keyword specifies the image copy to which you want to recover. If you specify a full image copy data set, the image copy is the only data set that is used in the recovery. If you specify an incremental image copy, the recovery uses the incremental image copy, the full image copy on which it is based, and any intervening incremental copies.
You can recover multiple tablespaces simultaneously by specifying multiple TOCOPY statements with a RECOVER statement. Also, if you specify SORTLOG YES with TOCOPY, the indexes can be recovered concurrently with the tablespace.
Consider the following items when using this keyword:
  • If you specify DSNUM ALL, the specified image copy must be for the entire tablespace. If you specify a partition or data set to recover, the image copy data set must be for the same partition or data set or for the whole tablespace. Use only image copies that were made with SHRLEVEL REFERENCE or SHRLEVEL NONE. An image copy that was made with SHRLEVEL CHANGE can result in inconsistent data.
  • TOCOPY is not valid with FULLDSN, FULLDD, LIST, RECOVER DATABASE, OBJ-LIST, and REBUILD INDEX.
This keyword has the following format:
TOCOPY {
dataset-name
|LAST-COPY}
  • dataset-name
    Specifies the data set name to use as the TOCOPY parameter. Enter a fully qualified data set name. If multiple data sets have the same name, use TOVOLUME to identify the data set.
  • LAST-COPY
    Recovers to the most recent full or incremental image copy. SYSIBM.SYSCOPY is scanned to determine the fully qualified data set name of the last LP (local primary) image copy. If duplicates exist in SYSCOPY, then TOCOPY LAST-COPY is invalid. In this case, use TOVOLUME CATALOG with TOCOPY or use the TORBA option.
    If you use COPY-TYPE RECOVERY with TOCOPY LAST-COPY, SYSIBM.SYSCOPY is scanned for the most recent RP (remote primary) image copy. If the RP cannot be allocated,
    Fast Recover
    falls back to the latest RB (remote backup). If neither the RP nor RB can be allocated, the previous RP is used. This RP is followed by the previous RB, and so on.