Copying fields with FILEMGMT

From m204wiki
Revision as of 20:18, 27 January 2014 by ELowell (talk | contribs) (Created page with "<p>You use the Copy screen to copy one or more fields. The Copy can be to the same file (if just one field is copied) or to a different file. The fields can be either existing...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

You use the Copy screen to copy one or more fields. The Copy can be to the same file (if just one field is copied) or to a different file. The fields can be either existing or staged.

A Copy operation is performed as soon as you leave the Copy screen. The copied fields are staged for the DEFINE command.

Copying fields

Select the Copy Fields function (number 5) from the primary screen.

FILEMGMGT displays the Field Copy screen:

FILEMGMT Field Copy Screen Filename: ABC Inactive Fieldname: ** All Fields ** Copy to FILE: New Fieldname: ** All Fields ** ===> 1=HELp 2= 3=QUIt 4= 5= 6= 7= 8= 9= 10= 11= 12=END

 

The cursor is initially positioned at the Field Name prompt.

Copy screen input

FILEMGMT displays or prompts you for the following information.

Prompt Response
Filename FILEMGMT displays the name of the file that you entered on the primary screen, and indicates whether the file is Active or Inactive.
Field Name

FILEMGMT displays the name of the field that you entered on the primary screen. If you did not enter a name on the primary screen, FILEMGMT displays:

** All Fields **

Copy to FILE Type the name of the existing file to which FILEMGMT is to copy the field(s). This file can be the same as the file from which the copy is made, if you are not copying all fields.
New Fieldname or record on the primary screen:

If you entered a name for the source field:

Type the name of the new field to which FILEMGMT is to copy the source field. The field name cannot already exist.

  1. Press PF12 (END). FILEMGMT copies the field.

If you did not enter a name for the source field on the primary screen, FILEMGMT displays the following message:

** All Fields **

Do the following:

Do not type a new field name.

  1. Press PF12 (END). FILEMGMT copies all fields from one file to another. The copied fields have the same names as the original fields, but are prefixed (qualified) by the "Copy to FILE" name.

Note

A field is not copied to the target file if the file already contains a field with an unqualified name (name without the file name prefix) that is the same as the field name in the source file. FILEMGMT displays a WARNING MESSAGE when it copies all fields and finds entries with duplicate unqualified names. The WARNING MESSAGE indicates the number of fields that can be copied.