Re: looking for a term

From: mAsterdam <mAsterdam_at_vrijdag.org>
Date: Sat, 09 Jul 2005 22:35:46 +0200
Message-ID: <42d03525$0$5080$e4fe514c_at_news.xs4all.nl>


paul c wrote:
> the latest glossary reminded me of a ..uestion (sorry, the key on my
> keyboard that stands for the letter between 'p' and 'r' is broken) that
> i've been trying to phrase for some time.

Try alt-113 for q and alt-81 for Q (keep the Alt key down while pushing the numbers)

> here goes:
>
> E:
> emp# name addr
> ____
> 1 Ted 555 ...
> 2 Bill 23 ...
>
> let's say emp# is the only candidate key. if we keep nulls out of
> things, i'd say the above '3-d'/ternary relation has more meaning than
> the 2-d/binary relations i could project from it, ie. N{emp#,name} and
> A{emp#,addr}.

How would they differ in meaning?

A predicate for E would be:
E: The employee identified by <emp#> has a

    name <name> and lives at <addr>

(Another predicate for E could be:
E: The employee identified by <emp#> has a brother

    named <name> and a misstress living at <addr> but let's not go into that for now)

A corresponding predicate for N would be: N: The employee identified by <emp#> has a name <name>. A: The employee identified by <emp#> lives at <addr>.

> trying to use common lingo, i'd characterize the extra meaning as an
> implied constraint, for example, "if an employee has an employee number,
> he must have a name and he must have an address". whereas the same
> constraint isn't implied if my schema contains only the N and A relations.

You want "to keep nulls out of things". However, a row with E.emp#=3 and a null in <E.name> would be the equivalent of having a row with A.emp#=3 and no such row in N, no?

> two ..estions:
>
> 1) is there a well-known term that describes this situation?

Not that I know of.

> 2) if i natural join N and A, producing a result that matches the
> contents of E, am i introducing the constraint in some sense?

Only for the resulting view - but I'm not sure what you mean here. If it is enforced as a constraint - how could you insert into A - or into N?

> maybe this
> is the same as asking if i take the two projections of E above have i
> dispensed, in some sense, with that constraint?
Received on Sat Jul 09 2005 - 22:35:46 CEST

Original text of this message