Re: Do we always have to update or insert? Why can't we just relate?

From: Marshall Spight <marshall.spight_at_gmail.com>
Date: 18 Oct 2005 00:25:35 -0700
Message-ID: <1129620335.909516.79710_at_g44g2000cwa.googlegroups.com>


paul c wrote:

>

> lots of times designers don't even realize how much they are influenced
> by historical baggage they are carrying around in their heads.

Yes! This is an excellent point and you put it quite well.

> btw, i think Marshall didn't say that duplicate keys should be allowed.

Right. If we have a functional dependency A -> B and we assert (a=1, b=2) and later assert (a=1, b=3) then we have violated a constraint. But if instead we asserted (a=1, b=2) *again* there is no constraint violation.

In fact, come to think of it, I can't really think of a way to specify this constraint on insert such that it is a database constraint-- it can only be expressed as a precondition on the insert operation itself. I see this as further evidence that it's a design wart that shouldn't be there. Can anyone think of any preconditions on select, update, delete, etc? I can't.

Marshall Received on Tue Oct 18 2005 - 09:25:35 CEST

Original text of this message