Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Even better: since SQL has a tri-valued logic (T, F, Unknown) it can assign "Unknown" as the result of a test against NULL. That means that `3 = NULL` is not true, but `3 != NULL` is also not true. If testing against NULL were merely false, then you'd have the bizarre result that

  val > 3
and

  not (val <= 3)
might return different results!

(I was just teaching this today in my DB class! Fun.)



Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: