Museum

Home

Lab Overview

Retrotechnology Articles

⇒ Online Manual

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

PARAMETERS

QUALIFIERS

EXAMPLES

/ALLOCATION

/BACKUP

/BEFORE

/BY_OWNER

/CONCATENATE

/CONFIRM

/CONTIGUOUS

/CREATED

/EXCLUDE

/EXPIRED

/EXTENSION

/LOG

/MODIFIED

/OVERLAY

/PROTECTION

/READ_CHECK

/REPLACE

/SINCE

/TRUNCATE

/VOLUME

/WRITE_CHECK

HELP COPY — VMS 5.5-2H4

   Creates a new file from one or more existing files. The COPY
   command can do the following:

   o  Copy an input file to an output file.

   o  Concatenate two or more input files into a single output file.

   o  Copy a group of input files to a group of output files.

   Format

     COPY  input-filespec[,...] output-filespec

Additional information available:

PARAMETERSQUALIFIERSEXAMPLES

PARAMETERS

input-filespec[,...]
   Specifies the name of an existing file to be copied. Wildcard
   characters are allowed. If you do not specify the device or
   directory, the COPY command uses your current default device and
   directory. If you specify more than one file, separate the file
   specifications with either commas (,)  or plus signs (+).

output-filespec
   Specifies the name of the output file into which the input is
   copied.

   You must specify at least one field in the output file
   specification. If you do not specify the device or directory,
   the COPY command uses your current default device and directory.
   The COPY command replaces any other missing fields (file name,
   file type, version number) with the corresponding field of the
   input file specification. If you specify more than one input file,
   the COPY command generally uses the fields from the first input
   file to determine any missing fields in the output file.

   You can use the asterisk (*)  wildcard character in place of
   any two of the following: the file name, the file type, or the
   version number. The COPY command uses the corresponding field in
   the related input file to name the output file.

QUALIFIERS

Additional information available:

/ALLOCATION/BACKUP/BEFORE/BY_OWNER/CONCATENATE
/CONFIRM/CONTIGUOUS/CREATED/EXCLUDE/EXPIRED/EXTENSION
/LOG/MODIFIED/OVERLAY/PROTECTION/READ_CHECK
/REPLACE/SINCE/TRUNCATE/VOLUME/WRITE_CHECK

/ALLOCATION

      /ALLOCATION=number-of-blocks

   Forces the initial allocation of the output file to the specified
   number of 512-byte blocks. If you do not specify the /ALLOCATION
   qualifier, or if you specify it without the number-of-blocks
   parameter, the initial allocation of the output file is determined
   by the size of the input file being copied.

/BACKUP

   Modifies the time value specified with the /BEFORE or the /SINCE
   qualifier. The /BACKUP qualifier selects files according to the
   dates of their most recent backups. This qualifier is incompatible
   with the following qualifiers that also allow you to select files
   according to time attributes: /CREATED, /EXPIRED, and /MODIFIED.
   If you specify none of these four time qualifiers, the default is
   the /CREATED qualifier.

/BEFORE

      /BEFORE[=time]

   Selects only those files dated prior to the specified time.
   You can specify time as an absolute time, as a combination of
   absolute and delta times, or as one of the following keywords:
   TODAY (default), TOMORROW, or YESTERDAY. Specify one of the
   following qualifiers with the /BEFORE qualifier to indicate the
   time attribute to be used as the basis for selection: /BACKUP,
   /CREATED (default), /EXPIRED, or /MODIFIED.

   For complete information on specifying time values, see the VMS
   DCL Concepts Manual.

/BY_OWNER

      /BY_OWNER[=uic]

   Selects only those files whose owner user identification code
   (UIC) matches the specified owner UIC. The default UIC is that of
   the current process.

   Specify the UIC by using standard UIC format as described in the
   VMS DCL Concepts Manual.

/CONCATENATE

      /CONCATENATE (default)
      /NOCONCATENATE

   Creates one output file from multiple input files when you do
   not use wildcard characters in the output file specification.
   The /NOCONCATENATE qualifier generates multiple output files. A
   wildcard character in an input file specification results in a
   single output file consisting of the concatenation of all input
   files matching the file specification.

   Files from Files-11 On-Disk Structure Level 2 disks are
   concatenated in alphanumeric order; if you specify a wildcard
   in the file version field, files are copied in descending order
   by version number. Files from Files-11 On-Disk Structure Level 1
   disks are concatenated in random order.

/CONFIRM

      /CONFIRM
      /NOCONFIRM (default)

   Controls whether a request is issued before each copy operation to
   confirm that the operation should be performed on that file. The
   following responses are valid:

   YES       NO        QUIT

   TRUE      FALSE     Ctrl/Z

   1         0         ALL

             <Return>

   You can use any combination of uppercase and lowercase letters
   for word responses. You can abbreviate word responses to one or
   more letters (for example, T, TR, or TRU for TRUE), but these
   abbreviations must be unique. Affirmative answers are YES, TRUE,
   and 1. Negative answers include: NO, FALSE, 0, and pressing
   the Return key. Entering QUIT or pressing Ctrl/Z indicates that
   you want to stop processing the command at that point. When you
   respond by entering ALL, the command continues to process but no
   further prompts are given. If you type a response other than one
   of those in the list, DCL issues an error message and redisplays
   the prompt.

/CONTIGUOUS

      /CONTIGUOUS
      /NOCONTIGUOUS

   Specifies that the output file must occupy contiguous physical
   disk blocks. By default, the COPY command creates an output file
   in the same format as the corresponding input file. Also, by
   default, if not enough space exists for a contiguous allocation,
   the COPY command does not report an error. If you copy multiple
   input files of different formats, the output file may or may not
   be contiguous. You can use the /CONTIGUOUS qualifier to ensure
   that files are copied contiguously.

   The /CONTIGUOUS qualifier has no effect when you copy files to
   or from tapes because the size of the file on tape cannot be
   determined until after it is copied to the disk. If you copy a
   file from a tape and want the file to be contiguous, use the COPY
   command twice: once to copy the file from the tape, and a second
   time to create a contiguous file.

/CREATED

      /CREATED (default)

   Modifies the time value specified with the /BEFORE or the /SINCE
   qualifier. The /CREATED qualifier selects files based on their
   dates of creation. This qualifier is incompatible with the
   following qualifiers that also allow you to select files according
   to time attributes: /BACKUP, /EXPIRED, and /MODIFIED. If you
   specify none of these four time qualifiers, the default is the
   /CREATED qualifier.

/EXCLUDE

      /EXCLUDE=(filespec[,...])

   Excludes the specified files from the copy operation. You can
   include a directory but not a device in the file specification.
   Wildcard characters (* and %) are allowed in the file
   specification. However, you cannot use relative version numbers to
   exclude a specific version. If you specify only one file, you can
   omit the parentheses.

/EXPIRED

   Modifies the time value specified with the /BEFORE or the /SINCE
   qualifier. The /EXPIRED qualifier selects files according to their
   expiration dates. (The expiration date is set with the SET FILE
   /EXPIRATION_DATE command.) The /EXPIRED qualifier is incompatible
   with the following qualifiers that also allow you to select files
   according to time attributes: /BACKUP, /CREATED, and /MODIFIED. If
   you specify none of these four time qualifiers, the default is the
   /CREATED qualifier.

/EXTENSION

      /EXTENSION=n

   Specifies the number of blocks to be added to the output file each
   time the file is extended. If you do not specify the /EXTENSION
   qualifier, the extension attribute of the corresponding input file
   determines the default extension attribute of the output file.

/LOG

      /LOG
      /NOLOG (default)

   Controls whether the COPY command displays the file specifications
   of each file copied.

   When you use the /LOG qualifier, the COPY command displays the
   following for each copy operation:

   o  The file specifications of the input and output files

   o  The number of blocks or the number of records copied (depending
      on whether the file is copied on a block-by-block or record-by-
      record basis)

   o  The total number of new files created

/MODIFIED

   Modifies the time value specified with the /BEFORE or the /SINCE
   qualifier. The /MODIFIED qualifier selects files according to
   the dates on which they were last modified. This qualifier is
   incompatible with the following qualifiers that also allow you to
   select files according to time attributes: /BACKUP, /CREATED, and
   /EXPIRED. If you specify none of these four time modifiers, the
   default is the /CREATED qualifier.

/OVERLAY

      /OVERLAY
      /NOOVERLAY (default)

   Requests that data in the input file be copied into the existing
   specified file, overlaying the existing data, rather than
   allocating new space for the file. The physical location of the
   file on disk does not change.

   The /OVERLAY qualifier is ignored if the output file is written to
   a non-file-structured device.

/PROTECTION

      /PROTECTION=(ownership[:access][,...])

   Specifies protection for the output file. Specify the ownership
   parameter as system (S), owner (O), group (G), or world (W) and
   the access parameter as read (R), write (W), execute (E), or
   delete (D). The default protection, including any protection
   attributes not specified, is that of the existing output file.
   If no output file exists, the current default protection applies.

   For more information on specifying protection code, see the VMS
   DCL Concepts Manual.

/READ_CHECK

      /READ_CHECK
      /NOREAD_CHECK (default)

   Reads each record in the input files twice to verify that it has
   been read correctly.

/REPLACE

      /REPLACE
      /NOREPLACE (default)

   Requests that, if a file exists with the same file specification
   as that entered for the output file, the existing file is to be
   deleted. The COPY command allocates new space for the output file.
   In general, when you use the /REPLACE qualifier, include version
   numbers with the file specifications. By default, the COPY command
   creates a new version of a file if a file with that specification
   exists, incrementing the version number. The /NOREPLACE qualifier
   signals an error when a conflict in version numbers occurs.

/SINCE

      /SINCE[=time]

   Selects only those files dated after the specified time. You can
   specify time as an absolute time, a combination of absolute and
   delta times, or as one of the following keywords: TODAY (default),
   TOMORROW, or YESTERDAY. Specify one of the following qualifiers
   with the /SINCE qualifier to indicate the time attribute to be
   used as the basis for selection: /BACKUP, /CREATED (default),
   /EXPIRED, or /MODIFIED.

   For complete information on specifying time values, see the VMS
   DCL Concepts Manual.

/TRUNCATE

      /TRUNCATE
      /NOTRUNCATE (default)

   Controls whether the COPY command truncates an output file at the
   end-of-file (EOF) when copying it. By default, the allocation of
   the input file determines the size of the output file.

/VOLUME

      /VOLUME=n

   Places the output file on the specified relative volume number of
   a multivolume set. By default, the COPY command places the output
   file arbitrarily in a multivolume set.

/WRITE_CHECK

      /WRITE_CHECK
      /NOWRITE_CHECK (default)

   Reads each record in the output file after it was written to
   verify that the record was copied successfully and that the file
   can be read subsequently without error.

EXAMPLES

   1.  $ COPY TEST.DAT NEWTEST.DAT

     In this example, the COPY command copies the contents of the
     file TEST.DAT from the default disk and directory to a file
     named NEWTEST.DAT on the same disk and directory. If a file
     named NEWTEST.DAT exists, the COPY command creates a new
     version of the file.

   2.  $ COPY ALPHA.TXT TMP
       $ COPY ALPHA.TXT .TMP

     In this example, the first COPY command copies the file
     ALPHA.TXT into a file named TMP.TXT. The COPY command uses the
     file type of the input file to complete the file specification
     for the output file. The second COPY command creates a file
     named ALPHA.TMP. The COPY command uses the file name of the
     input file to name the output file.


   3.  $ COPY *.* PRTLND::*.*

     In this example, the COPY command copies all files within the
     user directory at the local node to the remote node PRTLND. The
     new files have the same names as the input file. You must have
     write (W) access to the default directory on remote node PRTLND
     for the command to work.

   4.  $ COPY BOSTON::DISK2:TEST.DAT;5
       _To: DALLAS"SAM SECReturn"::DISK0:[MODEL.TEST]TEST.DAT/ALLOCATION=50

     In this example, the COPY command copies the file TEST.DAT;5
     on the device DISK2 at node BOSTON to a new file named TEST.DAT
     at remote node DALLAS. The /ALLOCATION qualifier initially
     allocates 50 blocks for the new file TEST.DAT at node DALLAS.
     The access control string SAM SECReturn is used to access the
     remote directory.

Typewritten Software • bear@typewritten.org • Edmonds, WA 98026