###### Summary -

In this topic, we described about the below sections -

A relation condition specifies the comparison of two operands. The relational operator that joins the two operands specifies the type of comparison.

The relation condition is true if the specified relation exists between the two operands. The relation condition is false if the specified relation does not exist.

Comparisons are defined for the following -

- Two operands of class alphabetic
- Two operands of class alphanumeric
- Two operands of class numeric
- Two operands of different classes where each operand is one of the classes alphabetic or alphanumeric
- Two operands where one is a numeric integer and the other is class alphanumeric
- Comparisons involving indexes or index data items
- An alphanumeric group and any operand that has usage DISPLAY

The relation condition formats are below -

- General relation conditions

## General relation conditions -

Compares two operands either of can be an identifier, literal, arithmetic expression or index-name.

#### Syntax -

**operand-1 -**

The subject of the relation condition. Can be an identifier, literal or arithmetic expression.

**operand-2 -**

The object of the relation condition. Can be an identifier, literal or arithmetic expression.

An alphanumeric literal can be enclosed in parentheses within a relation condition. The relation condition must contain at least one identifier.

### Relational operators and their meanings -

Relational Operator | Meaning |
---|---|

IS GREATER THAN IS > > |
Greater than |

IS NOT GREATER THAN IS NOT > NOT > |
Not greater than |

IS LESS THAN IS < < |
Less than |

IS NOT LESS THAN IS NOT < NOT < |
Not less than |

IS EQUAL TO IS = = |
Equal to |

IS NOT EQUAL TO IS NOT = NOT = |
Not equal to |

IS GREATER THAN OR EQUAL TO IS >= >= |
Is greater than or equal to |

IS LESS THAN OR EQUAL TO IS <= <= |
Is less than or equal to |