Re: Codd's Information Principle

From: <compdb_at_hotmail.com>
Date: Sat, 31 Oct 2009 17:39:52 -0700 (PDT)
Message-ID: <a4426942-396f-426a-a4e0-7c509fb98ce8_at_m26g2000yqb.googlegroups.com>


[Quoted] On Oct 30, 9:41 pm, paul c <toledobythe..._at_oohay.ac> wrote:
> com..._at_hotmail.com wrote:
> > On Oct 28, 12:51 pm, paul c <toledobythe..._at_oohay.ac> wrote:
> ...
> >> "Each row of the join represents a
> >> conjunction of propositions, one for each operand"
>
> > This doesn't make sense. Perhaps "one from each operand"?
> > If so, yes. The predicate associated with r JOIN s is
> > (predicate associated with r) AND (predicate associated with s).
> > So each result tuple present makes this true and
> > each result tuple absent makes this false.
> > ...
>
> I was quoting Mr. Scott.

[Quoted] Yes, I know, that's why I left in your double quotes.

> Regardless, I don't agree with either
> interpretation. I realize that many, perhaps most, people who have been
> trained in logic or read about it would place my attitude somewhere
> between unfaithful and ignorant, but I would never try to tell a user
> that some predicates are conjunctions and some aren't.

[Quoted] The user *doesn't* have any choice.

Assume variables (base relations) v with attributes ai and predicate (statement about the world) P and w with attributes bi and predicate Q.
P and Q are chosen by the designer.
The user set the value of v and w having observed the world.

If variable v={t | P(a1 t.a1, ...)} and variable w={t | Q(b1 t.b1, ...)}
(using named operands) then it is unavoidably true that (v JOIN w) = {t | P(a1 t.a1, ...)} AND Q(b1 t.b1, ...)}. Suppose v={<joe, 10>, <mary, 20>} with P "a1 is a2 years old" and w={<joe>, <sue>, <john>} with Q "a1 has a cat". (ie joe is 10 and marry is 20 and no one else is any age). Then (v JOIN w)={t| a1 is a2 years old and has a cat"} ie {<joe, 10>} (ie the names and ages of those people who have cats. So "joe is 10 and has a cat" is true and "mary is 20 and has a cat" is false
and every other statement of the form "a1 is a2 has a cat" is false too.
(This is just an example following my original message.)

This is why the operators of the relational algebra manipulate tuples as they do.
The algebra plus this fact is essentially the relational model: that the dbms calculates the tuples satisfying a transformation of predicates
(in the users head) by evaluating the corresponding relation operator on the
corresponding relations (in the database).

philip Received on Sun Nov 01 2009 - 01:39:52 CET

Original text of this message