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

From: Roy Hann <specially_at_processed.almost.meat>
Date: Tue, 18 Oct 2005 07:49:16 +0100
Message-ID: <Rdqdnc3wur2IBsneRVnyjg_at_pipex.net>


"Gene Wirchenko" <genew_at_ucantrade.com.NOTHERE> wrote in message news:r9d8l1dusvfosjr4l3f699lf6d65r6lto4_at_4ax.com...
> On 17 Oct 2005 16:28:22 -0700, "JOG" <jog_at_cs.nott.ac.uk> wrote:
>
> >Given two sets {2, 3, 4} and {3, 4, 5}, if I wanted to perform a union
> >upon them, I would expect to get the result {2, 3, 4, 5} and not an
> >error message stating the 3 and 4 existed in both. Is this analagous to
> >an insert? If this is the case, with an insert viewed as the union of
> >the relation's existing set of elements with specified insert set
> >(which just contains a single element), then from a purely theoretical
> >standpoint an error message does seem suprising.
>
> Good point on theory, but the inserts are one-at-a-time, so the
> analogy is not strong.
>
> My preference is that each action that I choose to do gets an
> appropriate response. If I am adding one row to a table, then
> another, then another, that is three actions, each with their own
> response. If my action is performing the union of two sets, then I
> expect the result you give above.

The problem here appears to be that you regard an insert as being *both* an assertion of a fact *and* assertion that it is a novel fact. That may be an entirely valid thing to want to assert, but it is an unusual thing to need to assert in the real world. My intuition (that is all it is) is that most business processes don't depend on facts being novel and it is a pointless complication. What is the point of having a database if you have to always already know what it is in it in order to know what you can assert is true about the business?

Obviously I am not arguing that key uniqueness doesn't matter!

Roy Received on Tue Oct 18 2005 - 08:49:16 CEST

Original text of this message