Free Trial

Safari Books Online is a digital library providing on-demand subscription access to thousands of learning resources.


  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • DownloadDownload
  • PrintPrint
Share this Page URL
Help

Chapter 3. Missing Values > NULL If you Must

NULL If you Must

As I mentioned earlier, I don't intend to get drawn into the debate on the proper use of NULLs. However, it's worth mentioning that, as a practical matter, NULL values in relational databases can be a royal pain. This is best illustrated by a couple of examples. Assuming we start with the following table and data:

CREATE TABLE #values (k1 int identity, c1 int NULL)
INSERT #values (c1) VALUES (1)
INSERT #values (c1) VALUES (1)
INSERT #values (c1) VALUES (NULL)
INSERT #values (c1) VALUES (9)


  

You are currently reading a PREVIEW of this book.

                                                                                        

Get instant access to over
$1 million worth of books and videos.

  

Start a Free Trial