Re: Plural or singular table names

From: Bob Badour <bbadour_at_golden.net>
Date: Thu, 4 Sep 2003 08:30:05 -0400
Message-ID: <TpH5b.479$rt5.47174800_at_mantis.golden.net>


"Marshall Spight" <mspight_at_dnai.com> wrote in message news:bqz5b.263499$Oz4.69861_at_rwcrnsc54...
> "Bob Badour" <bbadour_at_golden.net> wrote in message

news:m6y5b.465$EE4.45821030_at_mantis.golden.net...

> > "Marshall Spight" <mspight_at_dnai.com> wrote in message
> > news:0sv5b.163742$2x.45738_at_rwcrnsc52.ops.asp.att.net...
> > > But I'm unable to figure out how what you're saying might apply to
> > > a relcon. Can you give me an example of an operation on one or
> > > two relational values and an associated operator that would be
> > > affected by the presence of a candidate key?
> >
> > The candidate keys affect the type of the result of just about every
> > operation. Consider two ternary relations that each have attributes A,
B,
> > and C where the only candidate key of one relation is { A } and the only
> > candidate key of the other relation is { C }. Consider the result of the
> > project operation over { B, C }
> >
> > The candidate key of the project will be { B, C } for the first relation
and
> > { C } for the second relation. The results have different types. Now, it
is
> > possible that both relations contain the same set of tuples where { C }
is
> > incidentally unique for the first relation and where { A } is
incidentally
> > unique for the second. Even though the set of tuples in both operands
and
> > the set of tuples in both results are the same, the types differ.
>
> The question being discussed is whether relation values have constraints,
> and in particular whether they have key constraints. I can see how the
above
> explanation works if I have already accepted the idea that relation
> values have keys, but I do not see how it leads me to accept that
> idea if I haven't already.

Are you suggesting you reject the information principle and logical identity?

> You also now seem to be including the idea that constraints
> are part of the type. This also strikes me as unusual.

Specialization by Constraint seems unusual to you? As soon as you take one type and constraint it, you have created a new type.

> > > I guess I'm also assuming (much less solidly) that when you say
> > > candidate key, here, you are saying something *beyond* the
> > > fact that the rows must be unique. We would all agree (I hope!)
> > > that the members of a relation value are unique; I generally
> > > consider that part of the definition of relation, rather than
> > > that the definition includes the requirement of at least one
> > > candidate key, and that uniqueness is a consequence of
> > > that key.
> >
> > The two definitions are equivalent. Every relation having at least one
> > irreducible key implies unique tuples and vice versa.
>
> The two definitions have the same effects, but they are not equivalent.
> They are especially not equivalent when considering the question
> of whether relation values have keys or not, because one of them
> assumes that relation values have keys and the other doesn't.

I don't see that. If all relations have logical identity, they all have at least one irreducible key. If all relations have one irreducible key, they all have logical identity. Values, variables, expressions and literals do not come into consideration.

> Also, I can see how:
>
> every relation has a key -> unique tuples
>
> but I don't see how
>
> unique tuples -> every relation has a key.

The latter implies that the set of all attributes is a (possibly irreducible) superkey, which implies that the relation has at least one key.

> Foldoc gives this definition for constraint: "A Boolean relation,
> often an equality or ineqality relation, between the values of
> one or more mathematical variables (often two)."
>
> Also, I checked a few places in TTM, but could only find references
> to constraints on variables (database or relation variables) and
> constraints on types. (Admittedly, this is just appeal to authority,
> and not definitive.)

You found no reference to specialization by constraint or to generalization by constraint? You found no suggestion that values have types? Received on Thu Sep 04 2003 - 14:30:05 CEST

Original text of this message