On Thu, 18 Apr 2002 [EMAIL PROTECTED] wrote:

> I understand your warnings against a primary key having any informational
> content, though this admonition has always made me wonder why we still have
> composite keys around.  In the context of Torque, it again makes me wonder,
> why do we have ComboKey around?

Backwards compatability.

<cut>

> I may, as you suggest, add a new column--say RECORD_ID--and make it the
> simple primary key, thus stripping all information from the primary key as
> you suggest.  One consequence of this is that I will no longer be looking
> things up by their primary key, but instead by a combination of two
> attributes.

Yes, but that is what you will essentailly be doing anyway, it just
doesn't tie you to always looking things up in that manner.  Your logic is
most likely going to look like :

transaction = getTransaction(x);
record = transaction.getGetRecordWithGreatestLogValue();

so I don't see what having a combo key gains you.  All of my tables have a
UNIQID column that is the primary key.  I've never come across a situation
where having a primary without meaning has hindered me.

-Kurt


--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to