Defining an Array Value Field

An array value field is one of the five derived fields you can define. It can access a specific value in an array, or sum the values in an array. Use this procedure to define an array value field.

For more information on array value fields, see Array Value Fields.

To define an array value field

  1. On the File Definition form, move the cursor to the blank line below the last defined field in the Field Name column. (If you do not want the field added at the end of the list, highlight the field just below where you want a new field inserted and press Insert (F8).)
  2. Type a field name and press Tab.
  3. In the Element field, type an element name and press Tab.

    The Select an Element Type for Element subform appears.

  4. Select the ArrVal Field derived type. The array field you want to base the array value field on must have a value in the Occurs field.
  5. On the Select An Array Field subform, select the array field.

    The Array Value Field Definition subform appears. The Array Value Name field defaults from the Field Name field on the File Definition form.

    The Array Field Name field displays the array field you selected. The system displays the number of times the array field occurs in the Occurs n Times field.

  6. Type or select a Subscript or a Range Subscript.

    Subscript uses another field or a value to subscript the array.

    A Range Subscript defines the end range of a summation array value. For example, to add the fourth, fifth, and sixth occurrences of a numeric array field, type 4 in the Subscript field and 6 in the Range Subscript field. This field does not appear for alpha, time, telephone, or date fields.

    1. Press Select (F4).
    2. To subscript the array by a field, choose Field, then select the field to subscript the array.
    3. To subscript the array by a value, choose Value, then type the value to subscript the array.
    4. Press Enter.
  7. To give the Array Value field a size, press Size (F6), type the array value field size, and press Enter.

    If you do not give the field a size, the system determines the type and size of the Array Value field based on the type and sizes of the fields used to define it.

  8. Press Enter twice.