Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!csd4.milw.wisc.edu!srcsip!nic.MR.NET!hal!ncoast!telotech!bsa From: bsa@telotech.UUCP (Brandon S. Allbery) Newsgroups: comp.databases Subject: Re: Ingres and referential integrities Keywords: Ingres referential integrities Message-ID: <1989Jul31.180936.9242@telotech.uucp> Date: 31 Jul 89 18:09:36 GMT References: <3081@rti.UUCP> <3225@rtech.rtech.com> <9677@alice.UUCP> Sender: bsa@telotech.uucp (Brandon S. Allbery) Reply-To: bsa@telotech.UUCP (Brandon S. Allbery) Distribution: comp Organization: _ telotech, inc. - Beachwood, OH Lines: 32 In-reply-to: debra@alice.UUCP (Paul De Bra) In article <9677@alice.UUCP>, debra@alice (Paul De Bra) writes: +--------------- | Then referential integrity (given EMPNO is a key in EMP and DNO a key in | DEPT) would imply that EMP cannot contain a DNO which does not occur in | DEPT. | | There should be no need for procedures or other low-level tricks to | enforce this constraint. +--------------- Why? Because referential integrity is, by natural law, the lowest-level form of integrity possible? Multi-table integrity via procedures allows you to define referential integrity. Moreover, it allows you to define forms of integrity which a hierarchical DBMS can not handle: for example, a database I designed once required the condition for integrity to be "... between xxx and yyy" instead of simply "=". Certainly, I could have designed it otherwise... and then would have been forced to explain why the database had to be fed magic codes instead of the values everyone was used to. Sorry, folks, but forcing people to conform to the DBMS's way of doing things isn't what I consider the right way to do things. (...segue to comp.info-systems.... 1/2 :-) RTI's got it right: their system permits referential integrity as *you* define it as a specific case of a much more general mechanism. ++Brandon -- Brandon S. Allbery @ telotech, inc. (I do not speak for telotech. Ever.) *This article may only be redistributed if all articles listed in the header's* * References: field, and all articles listing this one in their References: * * fields, are also redistributed. *