select * from table where order_id != 1
select * from table where (order_id != 1 or order_id is null)
18 & 19
NULL value can be surprising until you get used to it. Conceptually, NULL means “
a missing unknown value” and it is treated somewhat differently from other values.
To test for
NULL, use the
IS NULL and
IS NOT NULL operators
You cannot use arithmetic comparison operators such as
=, <, or <> to test for
Because the result of any arithmetic comparison with
NULL is also
NULL, you cannot obtain any meaningful results from such comparisons.