Adding record definitions with FILEMGMT: Difference between revisions
(Automatically generated page update) |
(Automatically generated page update) |
||
Line 463: | Line 463: | ||
<blockquote class="note"><b>Note:</b> A record is not copied to the target file if the file already contains a record with an unqualified name (name without the file name prefix) that is the same as the record name in the source file. FILEMGMT displays a <code>WARNING</code> message when it copies all records and finds entries with duplicate unqualified names. The warning messge indicates the number of records that can be copied. </blockquote> | <blockquote class="note"><b>Note:</b> A record is not copied to the target file if the file already contains a record with an unqualified name (name without the file name prefix) that is the same as the record name in the source file. FILEMGMT displays a <code>WARNING</code> message when it copies all records and finds entries with duplicate unqualified names. The warning messge indicates the number of records that can be copied. </blockquote> | ||
[[Category:FILEMGMT application subsystem]] | [[Category:FILEMGMT application subsystem]] |
Revision as of 04:20, 10 May 2014
Record maintenance
FILEMGMT provides you with an interface for performing all your record maintenance operations. This section describes how to perform the following operations:
- List records in new and existing files.
- Select the records you want to define, redefine, delete, and rename.
- Define and redefine records.
- Stage records in preparation for executing DEFINE, REDEFINE, DELETE, and RENAME commands.
Record Name List screen
To display the Record Name List screen, you can optionally:
- Press the F4 (RECords) key from the Field Attributes screen. FILEMGMT displays the Record Name List screen in DEFINE mode.
- Select a Record maintenance function from the primary screen. FILEMGMT displays the Record Name List screen in the mode corresponding to the selected function.
You use the Record Name List screen to:
- Specify the names and frequency of the records in a file you are creating. A record name represents a record type.
- View records in an existing file, define additional records, and select records you want to redefine, delete, or rename.
If you are defining new records for a new or existing file, FILEMGMT displays the Record Name List screen in DEFINE mode:
FILEMGMT Record Name List Line 1 of 11 Enter and select with an 'X' the records you want to DEFINE to the file Filename: PERSONNL | | No. of | Expected | Occurrence | | Recordname | Records | Increase (%) | in File | Cmd -------------------------------------------------------------------- X PERSONNL | ________ | ___ | 100.0% | _ ____________________ | ________ | ___ | | _ ____________________ | ________ | ___ | | _ ____________________ | ________ | ___ | | _ ____________________ | ________ | ___ | | _ ____________________ | ________ | ___ | | _ ____________________ | ________ | ___ | | _ ____________________ | ________ | ___ | | _ ____________________ | ________ | ___ | | _ ____________________ | ________ | ___ | | _ ____________________ | ________ | ___ | | _ ____________________ | ________ | ___ | | ===> 1=HELp 2=DOCument 3=QUIt 4=FIElds 5=WIDen 6=COMmands 7= 8=FORward 9=SIZe 10= 11=RECdefn 12=END |
The above record name list has an entry for a record name with the same name as the file. FILEMGMT creates this entry automatically.
You can perform these operations:
- Rename the entry by typing over the displayed name.
- Type additional record names, one record per line.
- Specify for each record name the number of records and expected increase to the number of records. (No. of Records is required input.)
- Proceed to the Record Definition screen to define the contents of the new entries.
If you are redefining, deleting, or renaming records, FILEMGMT displays the Record Name List screen in the mode corresponding to your requested function.
The following screen was invoked by selecting Redefine for Record on the primary screen:
FILEMGMT Record Name List Line 1 of 2 Select the records you want to REDEFINE with an 'X' Filename: PERSONNL | | No. of | Expected | Occurrence | | Recordname | Records | Increase (%) | in File | Cmd -------------------------------------------------------------------- _ EMPLOYEE | 1000 | ___ | 29.4% | *** _ DEPENDENTS | 2000 | 20 | 70.6% | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ===> 1=HELp 2=DOCument 3=QUIt 4=FIElds 5=WIDen 6=COMmands 7= 8= 9=SIZe 10= 11=RECdefn 12=END |
If you specified a particular record name on the primary screen, FILEMGMT displays an X
in the prefix area of this record.
Staged records display the command for which they are staged in the Cmd column. Nonstaged records have a blank in the Cmd column, as in the above screen. Staging is discussed in Staging entries.
You can scroll forward and backward to view additional record names by pressing the F8 (FORward) and F7 (BACkward) keys. You can scroll forward 100 lines, which corresponds to FILEMGMT's record number limit.
Record Name List 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. | ||||||||||||
Recordname |
If you are creating a new file, FILEMGMT displays a single record name that is the same as the file name. If you are viewing an existing file and did not specify a particular record name on the primary screen, FILEMGMT lists all the records in the file. | ||||||||||||
Cmd |
Displays the status of the record shown on the line:
A record's Cmd status determines whether you can issue a particular command for the record. Command status, below, is a table that summarizes your options (where an |
||||||||||||
No. of Records | Type the number of records of the specified record name to be stored in the file. For a new file, the number represents the initial number of records. Valid values are:
|
||||||||||||
Expected Increase (%) | Type the expected percentage of increase (0-100) in the number of records of the specified record name. The number represents the expected increase during the life of the file. If you do not enter a number in this column, FILEMGMT uses only No. of Records to calculate the size of the file. | ||||||||||||
Occurrence in File | FILEMGMT computes this value from No. of Records and Expected Increase, and it displays the value. |
Record operations
Follow these steps to stage records for a particular function.
Defining records
To DEFINE records:
- Enter the record names in the Recordname column.
To enter new record names, type in the names (1-70 characters). Use the standard Model 204 naming conventions.
To enter new records for an existing file, type the names at the bottom of the list. To enter a record name that is longer than the space provided (20 characters), position the cursor on the record name. Press the F5 (WIDen) key to advance to the Widen screen.
You can remove new names before you end the session. Type a
D
in the prefix area to the left of the new name. The deletion removes a line from the display, but does not affect the physical data. - Type
X
to the left of the record names to select them. - Press F11 (RECdefn).
The Record Definition screen displays the records you selected in the order in which they are listed on the Record Name List screen. The records are staged for DEFINE.
Redefining records
To REDEFINE records:
- On the main menu, using the record option, select option 2.
- Type
X
to the left of the record names to select them. - Press F11 (RECdefn).
The Record Definition screen displays the records you selected in the order in which they are listed on the Record Name List screen. The records are staged for REDEFINE.
Deleting records
To DELETE records:
- On the main menu, using the record option, select option 3.
- Type
X
to the left of the record names to select them. - Press one of the following to stage the records for DELETE:
F2 (DOCument) F4 (FIElds) F6 (COMmands) F9 (SIZe) F11 (RECdefn) F12 (END)
Press F3 (QUIt) to cancel the deletion.
Renaming records
To RENAME records:
- On the main menu, using the record option, select option 4.
- Type
X
to the left of the record names to select them. - Type over the existing names. Press the F5 (WIDen) key to enter a name that has more than 20 characters.
- Press one of the following to stage the records for RENAME:
F2 (DOCument) F4 (FIElds) F6 (COMmands) F9 (SIZe) F11 (RECdefn) F12 (END)
Press F3 (QUIt) to cancel the operation.
Command status
Command Status | |||||||
---|---|---|---|---|---|---|---|
Command | New | Staged as | Existing | ||||
*** | DEFINE | REDEFINE | DELETE | RENAME | |||
DEFINE | X | X | X | ||||
REDEFINE | X | X | X | ||||
DELETE | X | X | |||||
RENAME | X | X | X |
Record Name List screen commands
To issue a command, press an F (function) key or type a command name at the prompt (===>) and press Enter.
Key | Command | Meaning |
---|---|---|
F1 | HELp | Displays HELP text for the Record Name List screen. |
F2 | DOCument | Invokes the Dictionary/204 Documentation facility. Place the cursor over the record name that you want to document and press F2. Changes to the Record Name List screen are saved in the dictionary. |
F3 | QUIt | Exits from the Record Name List screen and returns to the previous screen without making any changes. |
F4 | FIElds | Proceeds to the Field Name List screen. This screen lists the fields in the file. Changes to the Record Name List screen are saved in the dictionary. |
F5 | WIDen | Proceeds to the Widen screen. This screen allows you to expand the length of the record name on the Record Name List screen. |
F6 | COMmands | Proceeds to the Execute Commands screen. This screen displays the staged commands that were generated for the file and allows you to select the commands you want to execute. Changes to the Record Name List screen are saved in the dictionary. |
F7 | BACkward | Scrolls backward one screen. If you type BAC at the prompt (===>), followed by a number, FILEMGMT scrolls backward the specified number of lines. |
F8 | FORward | Scrolls forward one screen. If you type FOR at the prompt (===>), followed by the number, FILEMGMT scrolls forward the specified number of lines. |
F9 | SIZe | Proceeds to the File Size Definition screen. This screen displays information about the size of the file. Changes to the Record Name List screen are saved in the dictionary. |
F11 | RECdefn | Proceeds to the Record Definition screen. This screen defines the records you just selected from the list. Changes to the Record Name List screen are saved in the dictionary.
When you return from the Record Definition screen, the |
F12 | END | Exits from the Record Name List Screen and returns to the primary screen. Changes to the Record Name List screen are saved in the dictionary. |
Copying records
Select the Copy function (number 5) for Record from the primary screen. FILEMGMT displays the appropriate Copy screen.
You use the Copy screen to copy one or more records. The Copy can be to the same file (if just one record is copied) or to a different file. The records can be either existing or staged.
A Copy operation is performed as soon as you leave the Copy screen. The copied records are staged for the DEFINE command.
The cursor is initially positioned at the Recordname 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. |
Recordname | FILEMGMT displays the name of the record you entered on the primary screen. If you did not enter a name on the primary screen, FILEMGMT displays:
** All Records ** |
Copy to FILE | Type the name of the existing file to which FILEMGMT is to copy the record(s). This file can be the same as the file from which the copy is made, if you are not copying all records. |
New Fieldname or New Recordname: | If you entered a new record name for Field, Record or Field Group Name on the primary screen:
If you did not enter a name for the source record on the primary screen, FILEMGMT displays the following message: ** All Records ** Do the following:
|
Note: A record is not copied to the target file if the file already contains a record with an unqualified name (name without the file name prefix) that is the same as the record name in the source file. FILEMGMT displays a
WARNING
message when it copies all records and finds entries with duplicate unqualified names. The warning messge indicates the number of records that can be copied.