Search code examples
mysqldatabasesqlitenulloperator-keyword

What is the equivalent of the null-safe equality operator <=> in SQLite?


I need to determine what is the equivalent for SQLite of the <=> operator in MySQL.

Any idea?


Solution

  • The IS and IS NOT operators work like = and != except when one or both of the operands are NULL. In this case, if both operands are NULL, then the IS operator evaluates to 1 (true) and the IS NOT operator evaluates to 0 (false)

    http://www.sqlite.org/lang_expr.html#isisnot