MOVE Statement

<move statement>

── MOVE ─┬──────────────────────────────────────────┬──────────────────►
         │ ┌◄─────────────────────────────────────┐ │
         └─┴─┬─ & ───┬─┬─ /1\ ── BECOMEOWNER ───┬─┴─┘
             └─ AND ─┘ ├─ /1\ ─┬─ COMPARE ──────┤
                       │       └─ VERIFY ───────┤
                       ├─ /1\ ─┬─ DSONERROR ────┤
                       │       └─ WAITONERROR ──┤
                       ├─ /1\ ── PROPAGATE ─────┤
                       ├─ /1\ ── REPORT ────────┤
                       ├─ /1\ ── SELECT ────────┤
                       └─ /1\ ── SKIPEXCLUSIVE ─┘
  ┌◄──────────── , ────────────┐
►─┴─┬─<long file name >──────┬─┴─┬───────────────────────┬─────────────►
    └─<long directory name >─┘   └─ FROM ──<family name>─┘
►─ TO ──<family name>─┬────────────────────────────────────────┬───────┤
                      └─ ( ── FAMILYINDEX ── = ──<number>── ) ─┘

Explanation

The MOVE statement causes library maintenance to copy a disk file or files from one disk family to another disk family, and then remove the original file.

When library maintenance successfully copies a file from a source disk to the destination disk, it will remove the original file from the source disk. In addition, it will move any archive backup information for each file copied from the source disk archive directory to the destination disk directory. On cataloging systems, library maintenance will also move the catalog backup information for each file successfully from the source family catalog directory to the destination file catalog directory.

If there already is a file, catalog, or archive information for the file you are copying on the destination disk, library maintenance will remove the old file from the destination disk including any archive or catalog information for that file.

The MOVE statement will cause the catalog and/or archive backup information to be moved even if there is not a resident version of a requested file on the source family.

The MOVE statement cannot be used for a host/file transfer.

In the following cases, when the file and its backup information are copied to the destination volume, the backup information is purged from the source volume, but the source file is not removed:

  • When LOCKEDFILE = TRUE is set

  • When a system file is moved

Family substitution is used if the job or task has an active family specification. Only the primary family name is used. Refer to FAMILY Assignment and Interrogating Complex Task Attributes.

You can use the HI (Cause Exception Event) system command to check the progress of a MOVE statement. A command of the form <mix number> HI displays the number of files already copied and other information.

To avoid conflict with the MOVE system command, a question mark must precede the WFL MOVE statement entered at an ODT. The following options are available in the MOVE statement.

BECOMEOWNER

Controls the ownership of the destination directories and files moved within the permanent directory namespace. This option causes the OWNER attribute to be set to the usercode of the task performing the operation rather than having the value copied from the source.

All other attribute values, including those for GROUP and SECURITYMODE, are copied from the source. If a nonprivileged user issues a COPY or ADD statement without the BECOMEOWNER option, only the source directories and files already owned by that user are included.

COMPARE

Ensures the new copies of the files are written correctly. Ensures the new copies of the files are readable and the data in the copied files matches the data in the source files. This option compares the copied file and the original file bit by bit, immediately after the file is copied.

DSONERROR

Causes library maintenance to terminate with a DS response whenever

  • A file or directory to be copied is missing, and library maintenance issues a “file name FILE NOT ON source volume” message.

  • An error prevents a file from being copied to the destination.

  • Library maintenance issues a “RECOPY REQUIRED” RSVP, and the operator replies with DS, FR, or OF.

FAMILYINDEX

Designates a specific physical volume within a disk family. If you do not specify the FAMILYINDEX attribute, the FAMILYINDEX attribute (if any) of each file being moved is used. For further information, see the COPY or ADD Statement.

PROPAGATE

Enables moved files and permanent directories to inherit the security of the destination directory. This option applies only when the destination PROPAGATESECURITYTOFILES or PROPAGATESECURITYTODIRS attribute of the directory so specifies.

REPORT

Causes library maintenance to print a report of the copied files, including errors. When & REPORT is specified, library maintenance does not write “file copied” messages in the job log or in the system sumlog.

SELECT

Causes library maintenance to call the LIBMAINTSELECTOR procedure in the ARCHIVESUPPORT library for each file to be copied. You or your site can code a special version of the LIBMAINTSELECTOR procedure that indicates if the file should be copied or not.

For information on how to code a custom LIBMAINTSELECTOR procedure, refer to the SYMBOL/ARCHIVESUPPORT DCALGOLSYMBOL file and the MCP System Interfaces Programming Reference Manual.

SKIPEXCLUSIVE

Causes the system to not move those files from disk that are opened with EXCLUSIVE=TRUE or that are KEYEDIOII files marked as being updated.

VERIFY

Ensures the new copies of the file were written correctly. Ensures the new copies of the files are readable and that the data was copied accurately. For further details, see COPY or ADD Statement.

WAITONERROR

Causes library maintenance to issue an RSVP message whenever an error occurs. Examples of possible errors include:

  • Requesting a file or directory that is missing.

  • An error prevents a file from being copied to one or more destinations.

  • The RSVP message halts library maintenance until the operator or programmer responds with OK or DS. A response of OK causes library maintenance to continue the copy with other files or tapes. A response of DS will terminate the library maintenance program. After investigating the error that created the RSVP message, you can restart library maintenance.