View Record Layout function
The View Record Layout function enables you to view COBOL or PL/I record layouts as File-AID has interpreted them. The function consists of specifying the data set and member name of the record layout to view.
This section describes the two screens presented in the View function.
View record layout — dataset specification
The following figure allows you to view record layouts as File-AID has interpreted them. To access the View function, select option 8 from the File-AID Primary Option Menu or enter the appropriate jump command (for example, =8) from any File-AID screen. See Selecting-screens. The View function can also be accessed with the F8 recursive command. See Recursive Commands.
View Record Layout — Dataset Specification screen
COMMAND ===>
Specify Record Layout Dataset to View:
Dataset name ===> FASAMP.LAYOUTS
Member name ===> (blank or pattern for member list)
Expand Occurrences ===> Y (Y=YES,N=NO)
Field Descriptions
Dataset name and Member name
Specify the dataset name and member of the record layout you want to view. You can use a pattern character when specifying a dataset name. You can also specify a member name, in parentheses, along with the dataset name in the Dataset name field. For more information on specifying data set and member names, see Pattern dataset names.
Enter the FILELIST primary command or blank out the Dataset name field to display the Last Referenced File List. For more information, see Last Referenced File List.
Specifying a Concatenation List
To specify a concatenation list to be used in place of the Record Layout dataset, enter a plus sign followed by the member name (+membername) of the member containing the list. Enter this in the Record layout dataset field instead of the Record Layout dataset name. For example, if the member RLPROD contains the list to be used, enter +RLPROD instead of a Record Layout Dataset name. You specified the name of the concatenation list data set in Option 0.1, File-AID system parameters (see Concatenation List DSN). The concatenation list data set contains members known as concatenation lists. Each such list contains names of record layout datasets, each of which in turn contains record layout members.
The concatenation list is used in place of the single Record Layout dataset name. If the concatenated libraries contain duplicate member names, File-AID will always select the first occurrence of the member name.
Expand occurrences
When a record layout which contains an OCCURS or ODO you can specify to view all occurrences (YES) or only the first occurrence of each field.
Y
(Default) View all occurrences.
N
View only the first occurrence.
- Only the first occurrence of an OCCURS/ODO is displayed
- Each field number is displayed once
- Displayed FLD START position is for the first occurrence
After entering the record layout dataset information, press Enter to display the next screen. If you did not specify a member name or you entered a pattern character in the Member name field, a Member List is displayed before the next screen. Use the END (PF3), RETURN (PF4), or a jump command to exit the View Record Layout function.
View Layout
After you press Enter from the View Record Layout - Dataset Specification screen, the View Layout screen is displayed. This screen displays the field level and name, picture, starting and ending positions, and length for each item in the record layout. The field level and name are presented in a format similar to Edit Formatted mode.
The following figure shows the View Layout screen for a COBOL layout. COBOL Record Layout — FASAMP.LAYOUTS(EMPLOYEE) shows the same portion of the corresponding record layout.
View Layout — COBOL
COMMAND ===> SCROLL ===> CSR
Layout: USERID9.FASAMP.LAYOUTS(EMPLOYEE)
c EMPLOYEE-MASTER-
FILE 1 198 198
5 EMP-NUMBER X(5) 1 1 5 5
5 EMP-LAST-NAME X(15) 2 6 20 15
5 EMP-FIRST-NAME X(10) 3 21 30 10
5 EMP-MID-INIT X 4 31 31 1
5 FILLER XX 5 32 33 2
5 EMP-TITLE X(30) 6 34 63 30
5 EMP-PERSONAL-INFO GROUP 7 64 86 23
10 EMP-NATL-ID-NUMBER 9(9) 8 64 72 9
10 FILLER X 9 73 73 1
10 EMP-DATE-OF-BIRTH X(6) 10 74 79 6
10 EMP-DOB-REDEF REDEFINES EMP-DATE-OF-BIRTH
10 EMP-DOB-REDEF GROUP 11 74 79 6
15 EMP-DOB-MM 99 12 74 75 2
15 EMP-DOB-DD 99 13 76 77 2
15 EMP-DOB-YY 99 14 78 79 2
10 EMP-HIRE-DATE X(6) 15 80 85 6
10 EMP-MARITAL-STATUS X 16 86 86 1
5 EMP-WITHOLD-INFO GROUP 17 87 101 15
COBOL Record Layout — FASAMP.LAYOUTS(EMPLOYEE)
05 EMP-NUMBER PIC X(5).
05 EMP-LAST-NAME PIC X(15).
05 EMP-FIRST-NAME PIC X(10).
05 EMP-MID-INIT PIC X.
05 FILLER PIC X(2).
05 EMP-TITLE PIC X(30).
05 EMP-PERSONAL-INFO.
10 EMP-NATL-ID-NUMBER PIC 9(9).
10 FILLER PIC X(01).
10 EMP-DATE-OF-BIRTH PIC X(6).
10 EMP-DOB-REDEF REDEFINES EMP-DATE-OF-BIRTH.
15 EMP-DOB-MM PIC 99.
15 EMP-DOB-DD PIC 99.
15 EMP-DOB-YY PIC 99.
10 EMP-HIRE-DATE PIC X(6).
10 EMP-MARITAL-STATUS PIC X.
05 EMP-WITHOLD-INFO.
10 EMP-LIFE-INS-WITHOLD-AMT PIC S9999V99.
10 EMP-NATL-TAX-WITHOLD-PCT PIC S999V99 COMP-3.
10 EMP-REGION-TAX-WITHOLD-PCT PIC S999V99 COMP-3.
10 EMP-LOCAL-TAX-WITHOLD-PCT PIC S999V99 COMP-3.
The following figure shows the View Layout screen for a PL/I layout. PL/I Record Layout — FASAMP.LAYOUTS(PLIEMP) shows the same portion of the corresponding record layout.
View Layout — PL/I
COMMAND ===> SCROLL ===> CSR
Layout: USERID9.FASAMP.LAYOUTS(PLIEMP)
-------- FIELD LEVEL/NAME --------- --PICTURE-- FLD START END LENGTH
EMPLOYEE_MASTER_FILE 1 198 198
5 EMP_NUMBER CHAR(5) 1 1 5 5
5 EMP_LAST_NAME CHAR(15) 2 6 20 15
5 EMP_FIRST_NAME CHAR(10) 3 21 30 10
5 EMP_MID_INIT CHAR(1) 4 31 31 1
5 FILLER CHAR(2) 5 32 33 2
5 EMP_TITLE CHAR(30) 6 34 63 30
5 EMP_PERSONAL_INFO GROUP 7 64 86 23
10 EMP_NATL_ID_NUMBER CHAR(9) 8 64 72 9
10 FILLER CHAR(1) 9 73 73 1
10 EMP_DATE_OF_BIRTH CHAR(6) 10 74 79 6
10 EMP_HIRE_DATE CHAR(6) 11 80 85 6
10 EMP_MARITAL_STATUS CHAR(1) 12 86 86 1
5 EMP_WITHOLD_INFO GROUP 13 87 101 15
10 EMP_LIFE_INS_WITHOLD_AMT PFXU(6,2) 14 87 92 6
10 EMP_NATL_TAX_WITHOLD_PCT DFX(5,2) 15 93 95 3
10 EMP_REGION_TAX_WITHOLD_PCT
DFX(5,2) 16 96 98 3
10 EMP_LOCAL_TAX_WITHOLD_PCT
PL/I Record Layout — FASAMP.LAYOUTS(PLIEMP)
5 EMP_NUMBER CHAR(05),
5 EMP_LAST_NAME CHAR(15),
5 EMP_FIRST_NAME CHAR(10),
5 EMP_MID_INIT CHAR(01),
5 FILLER CHAR(02),
5 EMP_TITLE CHAR(30),
5 EMP_PERSONAL_INFO,
10 EMP_NATL_ID_NUMBER CHAR(09),
10 FILLER CHAR(01),
10 EMP_DATE_OF_BIRTH CHAR(06),
10 EMP_HIRE_DATE CHAR(06),
10 EMP_MARITAL_STATUS CHAR(01),
5 EMP_WITHOLD_INFO,
10 EMP_LIFE_INS_WITHOLD_AMT PIC '9999V99',
10 EMP_NATL_TAX_WITHOLD_PCT FIXED DEC (5,2),
10 EMP_REGION_TAX_WITHOLD_PCT FIXED DEC (5,2),
The following figure shows the View Layout screen for a COBOL layout with Expand Occurrences NO.
View Layout — COBOL with Expand Occurrences NO
COMMAND ===> SCROLL ===> CSR
Layout: USERID9.FASAMP.LAYOUTS(INVFILE)
-------- FIELD LEVEL/NAME --------- --PICTURE-- FLD START END LENGTH
INVENTORY-RECORD 1 513 513
5 INV-PART-NO X(15) 1 1 15 15
5 INV-DESCRIPTION X(40) 2 16 55 40
5 INV-UNIT-OF-MEASURE XX 3 56 57 2
5 INV-UNIT-PRICE S9(5)V99 4 58 61 4
5 INV-STOCK-INFO(1) OCCURS 2 TIMES
GROUP 5 62 79 18
10 INV-WAREHOUSE(1) XXX 6 62 64 3
10 INV-STATUS(1) X(6) 7 65 70 6
10 INV-QTY-DATE(1) GROUP 8 71 79 9
15 INV-QTY-ON-HAND(1) S9(5) 9 71 73 3
15 INV-LAST-ORDER-DATE(1) X(6) 10 74 79 6
10 INV-BO-QTY-DATE REDEFINES INV-QTY-DATE
10 INV-BO-QTY-DATE(1) GROUP 11 71 79 9
15 INV-QTY-BACKORDERED(1) S9(5) 12 71 73 3
15 INV-BACKORDER-DATE(1) X(6) 13 74 79 6
5 INV-REORDER-INFO GROUP 14 98 107 10
10 INV-REORDER-LEVEL S9(5) 15 98 100 3
10 INV-REORDER-QUANTITY S9(5) 16 101 103 3
The starting and ending position, and length are shown for both elementary and group items.
From the record layout screen, you can do the following:
- Use the UP, DOWN, and LOCATE commands to scroll through the record layout. The scroll amount field is on line two of the screen.
- Use the END (PF3), RETURN, or a jump command to exit the View Record Layout screen.
If the member contains multiple 01-level structures, File-AID identifies how many layouts there are and displays a message line to identify the first and next layout(s). For example:
MEMBER CONTAINS 6 LAYOUTS
-------- FIELD LEVEL/NAME --------- --PICTURE-- FLD START END LENGTH
> > > > > START OF LAYOUT NUMBER 1 < < < < <
.
.
.
> > > > > START OF LAYOUT NUMBER 2< < < < <