SQL Reference Guide
>
SQL Reference Guide
>
Understanding the Elements of SQL Statements
>
SQL Operators
>
Comparison Operators
Was this helpful?
Comparison Operators
Comparison operators compare two expressions. SQL includes the following comparison operators:
Comparison Operator
Description
=
Equal to
<>
Not equal to
>
Greater than
>=
Greater than or equal to
<
Less than
<=
Less than or equal to
IS NOT DISTINCT FROM
Equal to, treating NULLs as equal
IS DISTINCT FROM
No equal to, treating NULLs as equal
The <> operator can also be specified as != or ^=.
All comparison operators are of equal precedence.
The equal sign (=) also serves as the assignment operator in
assignment operations
(see
Assignment Operations
).
Last modified date: 08/29/2024
This site works best with JavaScript enabled