PostgreSQL

Comparisons

Comparison operators are operators that evaluate to true or false.

List of comparison operators
Operator Description
= equals
< less than
> greater than
<= less than or equal to
>= greater than or equal to
<> does not equal

Syntax

SELECT <columns> FROM <table-name> WHERE <condition>; 

Example

SELECT name, founded FROM Companies WHERE founded < 1980; 
Result from Example #1
Name Founded
Walmart 1962
Disney 1923