Re: [SQL] referential integrity - Mailing list pgsql-sql

From Howie
Subject Re: [SQL] referential integrity
Date
Msg-id Pine.LNX.3.96.990804110659.19176N-100000@rabies.toodarkpark.org
Whole thread Raw
In response to referential integrity  (Ramanika <ramanika@flashmail.com>)
List pgsql-sql
On Wed, 4 Aug 1999, Ramanika wrote:

> I did not see this in the documentation anywhere.  Does postgresql
> support referential integrity?  like when creating a table REFERENCES
> table(column_id)?

not directly, no.  at least not yet :)  6.6 is rumoured to have full
support.

for now you can use refint ( $PGSQL_SRC_ROOT/contrib/spi/refint.* ), which
handles referential integrity.  check_primary_key() and
check_foreign_key() are the two functions involved.  youd also need two
triggers, one per table.

i could've sworn this got added to the FAQ...

---
Howie <caffeine@toodarkpark.org>   URL: http://www.toodarkpark.org
"The distance between insanity and genius is measured only by success."


pgsql-sql by date:

Previous
From: Herouth Maoz
Date:
Subject: Re: [SQL] datetime sample code?
Next
From: "Stéphane FILLON"
Date:
Subject: Cache lookup failed with FUNCTION + TRIGGER