I’m learning SQL after a long break in any sort of programming, by force of past habit I wrote NOT NULL instead of IS NOT NULL and the expected result still appeared. Is there a difference between these two things in any cases?
IS NULL and IS NOT NULL Conditions
The IS NULL condition is satisfied if the term that immediately precedes the IS keyword specifies one of the following undefined values:
- The name of a column that contains a null value.
- An expression that evaluates to null.
Conversely, if you use the IS NOT NULL operator, the condition is satisfied when the column contains a value that is not null, or when the expression that immediately precedes the IS NOT NULL keywords does not evaluate to null.
I’m not sure I understand.
It makes sense how IS NULL is different to IS NOT NULL but that’s not my question. My question is how IS NOT NULL is different to NOT NULL (if there is any difference)
p.s. sorry if I just misunderstood your answers
Sorry, that answer does not address your question, but is gives us some foundational background. What you might want to search is,
is not vs not
and specify sql in the search query.