Comparison Functions and Operators 12.4.2 Comparison Functions and Operators Table 12.4 Comparison Operators Name Description > Greater than operator >= Greater than or equal operator < Less than operator <> ,  != Not equal operator <= Less than or equal operator <=> NULL-safe equal to operator = Equal operator BETWEEN ... AND ... Whether a value is within a range of values COALESCE() Return the first non-NULL argument GREATEST() Return the largest argument IN() Whether a value is within a set of values INTERVAL() Return the index of the argument that is less than the first argument IS Test a value against a boolean IS NOT Test a value against a boolean IS NOT NULL NOT NULL value test IS NULL NULL value test ISNULL() Test whether the argument is NULL LEAST() Return the smallest argument LIKE Simple pattern matching NOT BETWEEN ... AND ... Whether a value is not within a range of values NOT IN() Whether a value is not within a set of values NOT LIKE Negation of simple pattern matching STRCMP() Compare two strings Comparison operations result in a value of  1  ( TRUE ),  0  ( FALSE ), or  NULL . These operations work for both numbers and strings. Strings are automatically converted to numbers and numbers to strings as necessary. The following relational comparison operators can be used to compare not only scalar operands, but row operands: = > < >= <= <> != The descriptions for those operators later in this section detail how they work with row operands. For additional examples of row comparisons in the context of row subqueries, see Section 13.2.11.5, “Row Subqueries” . Some of the functions in this section return values other than  1  ( TRUE ),  0  ( FALSE ), or  NULL .  LEAST()  and GREATEST()  are examples of such functions; Section 12.3, “Type Conversion in Expression Evaluation” , 2125