LESS_THAN

All functions > COMPARISON > LESS_THAN

Returns TRUE if the first value is strictly less than the second value

Signatures

Returns: TRUE if expr1 < expr2, FALSE otherwise, NULL if either value is NULL

LESS_THAN(expr1: T, expr2: T, [digits: BIGINT]) → BOOLEAN
sql
ParameterTypeRequiredDescription
expr1TYesFirst value to compare
expr2TYesSecond value to compare
digitsBIGINTNoOptional decimal precision for numeric comparisons

Notes

  • Both values must be of comparable types
  • NULL comparisons always return NULL (three-valued logic)
  • For strings, uses lexicographic (dictionary) ordering
  • For dates/timestamps, earlier dates are "less than" later dates
  • Supports optional decimal precision for numeric comparisons

See also

Last update at: 2026/03/03 16:47:38
Last updated: 2026-03-03 16:48:19