All About NULLs

NULLs and the quirks connected with them have come up several times in this chapter and in earlier chapters. In this section, we'll pull all those bits and pieces together and go into more detail about the conceptual problems of NULLs. Our goal is to help you avoid some of the mistakes that often result from misunderstandings about NULLs.

The first point to consider, although it is hardly reassuring, is that even the experts consider NULLs a pesky problem; some think they should be done away with altogether. Part of the difficulty with NULLs arises from the fact that they can represent a number of different kinds of incomplete information:

  • Data that may never be known (“present whereabouts” for an escaped criminal)

  • Data that isn't ...

Get Practical SQL Handbook, The: Using SQL Variants, Fourth Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.