ON NULLS AND EMPTY SETS (AND MINDS)
with Hugh Darwen and C. J. Date

 

 

 

From: Fabian Pascal

To: Hugh Darwen, Chris Date

Date: 11 Jun 2005

 

Thought you might get a kick out of this (posted as a weekly quote on 6/17/05).

 

But there is one fundamental value without which a model and a database cannot exist at all - it is NULL - and it has its semantics defined at the model and at the system level as absence ... Nulls are equivalent of empty set (absence, hole etc.) and I can imagine a model without any other elements but not without nulls. In other words, null is what any model starts from and after that we can add any other non-primitive elements we want to see :-) Those other elements may pollute the model or may be argued to be unnecessary, but not null values. Since nulls play such a role they are actually not true "values"( in the sense we use "normal" values, say, 5, 10 or "some text").

--Alex Savinov, conceptoriented.com

 

 

From: Hugh Darwen

To: Fabian Pascal

 

Somebody ought to gently ask Alex Savinov what his reference is for equating the word NULL with the empty set.  Is he aware that it is SQL's NULL that we are talking about, and that SQL's NULL is most certainly not the empty set?

 

In case he doubts this, it could be pointed out to him that the empty set has the property that the union of it with any set S yields S.  In other words, the empty set is the identity under union.  In SQL, an expression of the form SELECT ... FROM ... UNION NULL is a syntax error because NULL does

not denote a table.  The expression VALUES 1 UNION VALUES (CAST NULL AS INTEGER) is legal, but does not yield VALUES 1.  (In fact it yields a table with two rows.)

 

Another thing about the empty set is that it has the wonderful property of being the same thing as itself.  That is not the case with SQL's NULL.  In SQL, "X = X" does not evaluate to TRUE in the case where "X IS NULL" does evaluate to TRUE.

 

According to my understanding, Paul Schrieb wrote (in response to Savinov's nonsense):

 

I don't think the NULL or empty set of set theory is exactly the same as the NULL of relational database theory.

 

Somebody ought to ask Schrieb what his reference is, for the existence of any concept named NULL in relational database theory.  It certainly can't be Codd's 1970 paper, nor can it be anything written by Chris Date or me, including in particular The Third Manifesto (our attempt to clarify the relational model for modern readers).  If by any chance Schrieb is thinking of Codd's "Relational Model, Version 2" (Addison-Wesley, 1990), then I would point out that there has been no general acceptance of that rarely referenced text, which is rejected by, for example, Date and me.

 

But I'm not sure who wrote this (it looks like somebody for whom English is not the first language, because there's much of it that I can't even parse and so is unintelligible to me). 

 

The situation with NULLs clearly demonstrates some serious problems of the relational model. I personally do not see any problem with NULLs but I am not thinking in terms of relational model. I've read How to Handle Missing Information without Using Nullsand I am really surprised - it provides completely unacceptable "solution" - it compromises the whole relational model IMO. NULL values have an absolutely concrete meaning and it does not matter how we call them after that. And this meaning, the things with such a semantics, is the basis of the model. This semantics can be expressed as "the absence" of thing. Any model starts from empty state before it can be populated with other kind of things and this initial state is strongly associated with the semantics of absence. If something disappears, if something is deleted then actually we get null.

 

Nevertheless, I would like to ask this person what the phrase "compromises the whole relational model"

means.  I mean, how does one compromise a theory?  And what's all this about "populating" a model, as if a model is, like a database, some kind of variable?  What does the writer mean by the word "model" here?

 

In any case, my solution is the purest one I can think of that is in keeping with both the letter and spirit of the relational model.  (Of course it is unacceptable in the current state of the technology, as I point out in the presentation, but its main point is to raise requirements on the technology!)  As the writer doesn't give any reason for finding it unacceptable, I cannot possibly add anything more at this time.

 

 

From: Chris Date

To: Fabian Pascal

 

Unfortunately, Savinov's conclusions are based on a model over nulls and the empty set.

 

 

Ed. Note: These people should not be taken too seriously. Responding to them is a waste of time. These are just examples of the sad state of discourse in the industry. Chris' reply is just right, but I doubt that it will be understood by many.

 

 

Posted 8/12/05