Displaying only specific fields by number (DISPLAY)


The DISPLAY command references the File-AID-assigned field numbers. You can use the DISPLAY primary command to display several types of information including:

  • All or selected fields of a record
  • The display format (HEX for example) for individual layout fields
  • One or all redefinitions of the same data.

In this example, you request a display of only a few fields of this layout.

Browse - Formatted Mode (DISPLAY ONLY Command)

image2021-6-15_12-33-45.png

Steps:

  1. Type DISPLAY 1-6 16 21 ONLY in the COMMAND field.
    You can separate the field numbers by blanks or commas. You may specify individual fields and/or field ranges (two fields connected by a hyphen: a-b).
  2. Press Enter. Only the data items in fields 1 through 6, 16, and 21 are displayed as illustrated in the following figure.

Result of DISPLAY ONLY command

Browse - Formatted Mode - After DISPLAY ONLY Command

  File-AID - Browse - USERID9.FASAMP.EMPMAST ------------------------- COL 1  101
  COMMAND ===>                                                  SCROLL ===> PAGE
  RECORD:       1                EMPLOYEE-MASTER-FILE             LENGTH:     198
  ---- FIELD NUMBER/NAME ------ -FORMAT- ----+----1----+----2----+----3----+----4
  ******************************** TOP OF DATA **********************************
  1 EMP-NUMBER                    5/AN   00090
  2 EMP-LAST-NAME                15/AN   MARTIN
  3 EMP-FIRST-NAME               10/AN   EDWARD
  4 EMP-MID-INIT                  1/AN   M
  5 FILLER                        2/AN
  6 EMP-TITLE                    30/AN   AIRPLANE MANUFACTURER
    16 EMP-MARITAL-STATUS         1/AN   M
    21 EMP-LOCAL-TAX-WITHOLD-PCT
                                  3/PS   5.00
  ****************************** BOTTOM OF DATA *********************************








  Enter CHAR (character mode), VFMT (vertical format), UNFMT (unformatted)

More about the DISPLAY command

  • You can specify up to nine field numbers or field ranges, listed in any order.
  • The abbreviation for DISPLAY is DIS.
  • The ON, OFF, and ONLY parameters can be placed before, after, or in any position within the field list.
  • In formatted mode, the set of fields that you define with the DISPLAY command is associated with a record layout and reused each time a record is mapped to that layout. You can define a separate set of fields to be displayed for each record layout if an XREF is in use.
  • The SHOW NUMBER command is used to tailor the display to show the field numbers.
  • The FPRINT command generates a report of one or more records and uses the current SHOW and DISPLAY settings to determine which fields are to appear on the report. (What you see is what you get.)
  • Unicode fields:

    The DISPLAY parameters NATIONAL or UT16 interpret data as Unicode UTF-16 and convert it to EBCDIC via IBM conversion services with the terminal CCSID. When conversion fails, original data are displayed in hexadecimal format. Limited to even bytes.

    Important

    DISPLAY does not support Unicode UTF-8.

Excluding fields from the display

The DISPLAY OFF command can be used to hide additional fields.

Browse - Formatted Mode (DISPLAY OFF Command)

image2021-6-15_14-25-3.png

Steps:

  1. Type DIS 3-6 OFF in the COMMAND field.
  2. Press Enter. File-AID redisplays the screen, excluding fields 3-6
    (EMP-FIRST-NAMEEMP-MID-INITFILLER, and EMP-TITLE) from the display as illustrated in the following figure.

Result of DISPLAY OFF

Browse - Formatted Mode - After DISPLAY 3-6 OFF Command

File-AID - Browse - USERID9.FASAMP.EMPMAST -------------------------- COL 1  101
 COMMAND ===>                                                   SCROLL ===> PAGE
 RECORD:     1                EMPLOYEE-MASTER-FILE                LENGTH:     198

 ---- FIELD NUMBER/NAME ------ -FORMAT- ----+----1----+----2----+----3----+----4
 ******************************** TOP OF DATA **********************************
 1 EMP-NUMBER                    5/AN   00090
 2 EMP-LAST-NAME                15/AN   MARTIN
   16 EMP-MARITAL-STATUS         1/AN   M
   21 EMP-LOCAL-TAX-WITHOLD-PCT
                                 3/PS   5.00
 ****************************** BOTTOM OF DATA *********************************











 Enter CHAR (character mode), VFMT (vertical format), UNFMT (unformatted)

Adding fields to the display

A subsequent DISPLAY command only changes what is requested by the current command.

Browse - Formatted Mode (DISPLAY ON Command)

image2021-6-15_14-26-46.png

Steps:

  1. Type DIS 34 ON in the COMMAND field.
  2. Press Enter. File-AID redisplays the screen and adds field 34 to the set of currently displayed fields as illustrated in the following figure.

Result of DISPLAY 34 ON

Browse - Formatted Mode - After DIS 34 ON Command

File-AID - Browse - USERID9.FASAMP.EMPMAST -------------------------- COL 1  101
 COMMAND ===>                                                   SCROLL ===> PAGE
 RECORD:     1                EMPLOYEE-MASTER-FILE                LENGTH:     198
 ---- FIELD NUMBER/NAME ------ -FORMAT- ----+----1----+----2----+----3----+----4
 ******************************** TOP OF DATA **********************************
 1 EMP-NUMBER                    5/AN   00090
 2 EMP-LAST-NAME                15/AN   MARTIN
   16 EMP-MARITAL-STATUS         1/AN   M
   21 EMP-LOCAL-TAX-WITHOLD-PCT
                                 3/PS   5.00
   34 EMP-CON-HOME-PHONE        10/AN   4155556981
 ****************************** BOTTOM OF DATA *********************************










 Enter CHAR (character mode), VFMT (vertical format), UNFMT (unformatted)

Redisplaying all the fields of a record

To redisplay all fields, use the DISPLAY ALL command. No field numbers are allowed with this syntax.

Browse - Formatted Mode (DISPLAY ALL Command)

image2021-6-15_14-28-11.png

Steps:

  1. Type DIS ALL in the COMMAND field.
  2. Press Enter. File-AID redisplays the screen with all of the fields for record 1 as illustrated in the following figure.

Result of DISPLAY ALL

Browse - Formatted Mode - After DISPLAY ALL

File-AID - Browse - USERID9.FASAMP.EMPMAST ------------------------- COL 1  101
 COMMAND ===>                                                  SCROLL ===> PAGE
 RECORD:      1                 EMPLOYEE-MASTER-FILE             LENGTH:     198
 ---- FIELD NUMBER/NAME ------ -FORMAT- ----+----1----+----2----+----3----+----4
 ******************************** TOP OF DATA **********************************
 1 EMP-NUMBER                    5/AN   00090                                   
 2 EMP-LAST-NAME                15/AN   MARTIN                                  
 3 EMP-FIRST-NAME               10/AN   EDWARD                                  
 4 EMP-MID-INIT                  1/AN   M                                       
 5 FILLER                        2/AN                                           
 6 EMP-TITLE                    30/AN   AIRPLANE MANUFACTURER                   
 7 EMP-PERSONAL-INFO            23/GRP                                          
   8 EMP-NATL-ID-NUMBER          9/NUM  427890125                               
   9 FILLER                      1/AN                                           
   10 EMP-DATE-OF-BIRTH          6/AN   101954                                  
   15 EMP-HIRE-DATE              6/AN   920101                                  
   16 EMP-MARITAL-STATUS         1/AN   M                                       
 17 EMP-WITHOLD-INFO            15/GRP                                          
   18 EMP-LIFE-INS-WITHOLD-AMT   6/SNUM -3000.00                                
   19 EMP-NATL-TAX-WITHOLD-PCT   3/PS   -74.00                                  
   20 EMP-REGION-TAX-WITHOLD-PCT                                                
                                 3/PS   25.00                                   
   21 EMP-LOCAL-TAX-WITHOLD-PCT                                                 
 Enter CHAR (character mode), VFMT (vertical format), UNFMT (unformatted) 


Related topics

 

Tip: For faster searching, add an asterisk to the end of your partial query. Example: cert*