Fujitsu UDS/SQL V2.5 User Manual

Page of 324
Subschema DDL
User interface
192
  
 U929-J-Z125-9-76
Defining a condition 
Detailed information is provided in the COBOL2000 “
”.
88 condition-name
   
⎧VALUE IS  ⎫
   
⎨          ⎬ {literal-1[ THROUGH literal-2]},... .
   
⎩VALUES ARE⎭
The database programmer can make the execution of program statements dependent on 
conditions. A condition can be that certain items have certain item contents.
Such items are then referred to as condition variables. 
condition-name
 specifies the name assigned to the condition by the database programmer 
for reference purposes. The name must be assigned immediately following the description 
of the item which is to be the condition variable. 
literal-1
literal-2, etc. denote value ranges applicable for the condition. The condition is 
fulfilled if the item assumes a value within the specified value range. The value range can 
be described by several individual values as well as smaller value ranges within the larger 
ranges. It must be within the value range defined for the item. 
Several condition names and associated value ranges may be specified for one condition 
variable. 
Example
01  ORDERS
      .
      .
      .
    02  ORDER-STATUS PICTURE IS S9.
    88  FINISHED VALUE IS 1.
    88  OPEN     VALUE IS 0.
The condition FINISHED is met if the ORDER-STATUS item contains value 1. If it contains 
value 0, the OPEN condition is fulfilled.