Re: Examples of SQL anomalies?

From: JOG <jog_at_cs.nott.ac.uk>
Date: Mon, 7 Jul 2008 13:11:53 -0700 (PDT)
Message-ID: <0ee62b7a-9611-4fd0-9f8e-4faa50a3b9e4_at_56g2000hsm.googlegroups.com>


On Jul 5, 1:55 pm, goanna <spamt..._at_crayne.org> wrote:
> Marshall <marshall.spi..._at_gmail.com> writes:
> > What can be meaningfully asked is determined by the schema.
>
> Close. What can be meaningfully asked is determined by the meaning
> of the schema. In the case of nullable attributes, this must be
> specified, not guessed.
>
> > If the schema specifies that the weight attribute is nullable,
> > then the question of how much a shipment weighs in total
> > is a question that cannot be asked.
>
> If the schema specifies that the weight attribute is nullable,
> we need to know what, precisely, is the intended meaning of a
> null weight.

No we don't. It suffices to know that the question cannot be asked of the RM, whatever it was supposed to mean.

> If may mean that the weight is unknown, or it may
> mean that the weight attribute is not applicable to this entity
> (e.g. the weight of an electronic book), or it may mean ...
> In a badly designed schema it may unfortunately be used with
> more than one meaning without permitting them to be distinguished.
>
> Nulls are often but not exclusively used to mean unknown value.
> Failure to distinguish between different uses of null is the
> basis of most of these, rather pointless, arguments.

Again, no. Theoretically nulls do not belong where a value should be. This is not a comment on missing data, but on avoiding hemorrhaging the relational model's underlying mathematics. We should be able to do better than that in computer "science" after all. Received on Mon Jul 07 2008 - 22:11:53 CEST

Original text of this message