Rational Developer for System z
COBOL for Windows, Version 7.5, Language Reference


Format 2

Format 2: condition-name value
Read syntax diagramSkip visual syntax diagram>>-88--condition-name-1--+-VALUE--+----+---+-------------------->
                         |        '-IS-'   |  
                         '-VALUES--+-----+-'  
                                   '-ARE-'    
 
   .---------------------------------------.     
   V                                       |     
>----literal-1--+------------------------+-+--.----------------><
                '-+-THROUGH-+--literal-2-'       
                  '-THRU----'                    
 

This format associates a value, values, or ranges of values with a condition-name. Each such condition-name requires a separate level-88 entry. Level-number 88 and the condition-name are not part of the format-2 VALUE clause itself. They are included in the format only for clarity.

condition-name-1
A user-specified name that associates a value with a conditional variable. If the associated conditional variable requires subscripts or indexes, each procedural reference to the condition-name must be subscripted or indexed as required for the conditional variable.

Condition-names are tested procedurally in condition-name conditions (see Conditional expressions).

literal-1
Associates the condition-name with a single value.

The class of literal-1 must be a valid class for assignment to the associated conditional variable.

literal-1 THROUGH literal-2
Associates the condition-name with at least one range of values. When the THROUGH phrase is used, literal-1 must be less than literal-2, unless the associated data item is a non-year-last windowed date field. For details, see Rules for condition-name entries.

literal-1 and literal-2 must be of the same class. The class of literal-1 and literal-2 must be a valid class for assignment to the associated conditional variable.

The range of alphanumeric literals, national literals, or DBCS literals specified for the THROUGH phrase is based on the collating sequence in effect for the associated conditional variable. For more information about collating sequences, see Appendix G. Locale considerations.

If the associated conditional variable is of class DBCS, literal-1 and literal-2 must be DBCS literals. The figurative constant SPACE or the figurative constant ALL DBCS-literal can be specified.

If the associated conditional variable is of class national, literal-1 and literal-2 must be either both national literals or both alphanumeric literals for a given condition-name. The figurative constants ZERO, SPACE, QUOTE, HIGH-VALUE, LOW-VALUE, symbolic-character, ALL national-literal, or ALL literal can be specified.

Rules for condition-name entries


Terms of use | Feedback

Copyright IBM Corporation 1996, 2008.
This information center is powered by Eclipse technology. (http://www.eclipse.org)