Re: Nested Relations / RVAs / NFNF

From: Marshall Spight <mspight_at_dnai.com>
Date: Wed, 27 Oct 2004 17:35:07 GMT
Message-ID: <e%Qfd.325703$D%.86341_at_attbi_s51>


"erk" <eric.kaun_at_pnc.com> wrote in message news:1098891274.072545.198610_at_f14g2000cwb.googlegroups.com...
> Hi again Marshall - I'm just jumping in haphazardly here.

Hey hey-- how's it going? I'm on vacation, so it's All NetNews, All The Time for me, eh? :-)

> > So, on a related note, it's a little weird that we use integers as
> > keys.
>
> The key is a set of attributes, not the value of those attributes. The
> "key-ness" of an individual attribute (its membership in one or more of
> the candidate keys) is orthogonal to its type.

Sure. And that makes perfect sense for natural keys. But datatypes as such should support the appropriate operations-- no less, and no more, either. It doesn't make sense to have division on strings, eh? When we need a surrogate key, what are the desired characteristics we want for that datatype? It ain't addition. I'm trying to figure out what are the minimum characteristics for such a datatype, and as best I can figure, all we need are 1) create 2) test equal 3) copy, which actually strikes me as three things that every datatype *must* do. In fact, these are perhaps three things that might be good candidates for being system-defined operations rather than part of the type definition. (Putting equality in this category is probably controversial, but I've thought it belonged as systemdefined  since well before I started thinking about this particular issue.)

Can anyone think of anything else a datatype *must* do?

> > Integers support e.g. addition, so we are allowed to add
> > two keys together. This is nonsensical.
>
> You could say the same about strings or any other type; substring is a
> string operation, so you could nonsensically take the substring of a
> "key attribute".

Well, I suppose it wouldn't be nonsensical if the string was meaningful. An integer key is typically not meaningful beyond its identity as a key.

Hmmm. Okay, I guess now I see what you mean about the orthogonality of keyness and type. Still, I'm starting to see a semantic distinction between natural and surrogate keys.

Marshall Received on Wed Oct 27 2004 - 19:35:07 CEST

Original text of this message