VALUES (Values) Keyword for Display Files

Use this field-level keyword to specify a list of values that are valid for the user to type into the field. The OS/400 program performs an implied equals test on the data typed in against the value(s) you specify here. Note that the OS/400 program performs this checking only if the field is changed by the work station user or if its modified data tag (MDT) is set on using DSPATR(MDT).

Note:
Refer to the CHKMSGID keyword for information on defining user-specified error messages.

The format of the keyword is:

VALUES(value-1 [value-2... [value-100]])

There can be 1 to 100 values; specify them as parameter values with the keyword and separate them by at least one blank.

Note:
You cannot specify more than 5000 characters in a single DDS statement. Therefore, you cannot specify character values that cause VALUES to be longer than 5000 characters. If you specify other keywords for the same field, they also count toward the 5000-character limit. For example, specifying DSPATR(HI) for the field reduces the number of characters left for VALUES.

A value can be a numeric or a character value, corresponding in length to the field that is to be tested. A character value must be enclosed in apostrophes. A numeric value is restricted to the digits 0 through 9 and can be preceded by a minus sign (-) for negative values. Alignment is on the low-order character position.