COPY.LIST

COPY.LIST

Top  Previous  Next

 

The COPY.LIST command copies a saved select list to another file or a different record in the same file. Alternatively, the list can be output to the display.

 

 

Format

 

COPY.LIST src.list {, tgt.list} {FROM src.file} {TO tgt.file} {options}

 

where

 

src.listis the name of the saved select list that is to be copied. If src.list is given as *, all saved select lists in the source file are copied.

 

tgt.listis the name to be used for the copied select list. If omitted, the list retains its original name. A tgt.list name cannot be specified when copying all saved lists from the source file.

 

src.fileis the name of the file holding the src.list to be copied. If omitted, the default saved lists file $SAVEDLISTS is used.

 

tgt.fileis the name of the file to receive the copied select list. If omitted, the default saved lists file $SAVEDLISTS is used.

 

optionsmay be any of the following

 

CRTOutput the select list to the display. Neither tgt.list nor tgt.file may be specified with this option.

 

DELETINGDelete src.list after copying.

 

LPTR {n}Output the select list to logical print unit n. If n is not specified, the default print unit is used.

 

NO.PAGEUsed with the CRT option, this option suppresses the normal pause between successive pages of output.

 

OVERWRITINGIf tgt.list already exists in tgt.file, this option allows overwriting of the existing list. Without this option, a message is displayed and no copy occurs.

 

The COPY.LIST command is used to copy saved select lists. The FROM and TO options allow copying from and to files other than the default $SAVEDLISTS file. When the default file is used, it will be created if it does not already exist.

 

The COPY.LIST command does not affect any active select lists.

 

 

Example

 

COPY.LIST INVENTORY TO INVENT.LISTS OVERWRITING

 

This command copies the select list previously stored in $SAVEDLISTS as INVENTORY to a record of the same name in file INVENT.LISTS. Any existing record of the same name is overwritten.

 

 

See also:

DELETE.LIST, EDIT.LIST, GET.LIST, SAVE.LIST, SORT.LIST