Remarks

The Is operator has specific comparison functionality that differs from the operators in the following table. The following table contains a list of the comparison operators and the conditions that determine whether result is True, False, or Null:

Operator

Description

True if

False if

Null if

<

Less than

expression1 < expression2

expression1 >= expression2

expression1 or expression2 = Null

<=

Less than or equal to

expression1 <= expression2

expression1 > expression2

expression1 or expression2 = Null

>

Greater than

expression1 > expression2

expression1 <= expression2

expression1 or expression2 = Null

>=

Greater than or equal to

expression1 >= expression2

expression1 < expression2

expression1 or expression2 = Null

=

Equal to

expression1 = expression2

expression1 <> expression2

expression1 or expression2 = Null

<>

Not equal to

expression1 <> expression2

expression1 = expression2

expression1 or expression2 = Null

When comparing two expressions, you may not be able to easily determine whether the expressions are being compared as numbers or as strings.

The following table shows how expressions are compared or what results from the comparison, depending on the underlying subtype: