What are the different SQL Comparison Operators?
In previous lessons, we have discussed many of the different SQL comparison operators that are available. These operators give you plenty of options to filter data in the WHERE clause of your SELECT statement. Having discussed many of them, I want there to be one consolidated place for you to get information on each of the SQL comparison operators.
The table below contains the SQL comparison operator symbol and a description of what it does:
|SQL Comparison Operator||Description|
|>=||Greater than or equal to|
|<=||Less than or equal to|
|<>||Not equal to|
|!=||Not equal to|
|!<||Not less than|
|!>||Not greater than|
The table above lists all of the SQL comparison operators that you can use in your WHERE clause. You may notice that the IN, BETWEEN, and LIKE operators are not included in this table. Those are technically considered logical operators and have slightly different properties. Accordingly, this is why the IN, BETWEEN, and LIKE operators each have lessons dedicated to them.