[EMAIL PROTECTED] wrote:
Postgresql 8.1.4 on Redhat 9
I have a table which stores M:M relationships. I can't put foreign
keys to the parents of this table because the relationships being
stored go to several tables. This was done so that only two fields
have to be searched in order for all
Kenneth Downs [EMAIL PROTECTED] wrote on 03/06/2007 05:48:05 AM:
[EMAIL PROTECTED] wrote:
Postgresql 8.1.4 on Redhat 9
I have a table which stores M:M relationships. I can't put foreign
keys to the parents of this table because the relationships being
stored go to several tables.
I think a foreign key restraint is basically a trigger that throws an
exception (RAISE statement) when the restraint is violated.
Something trigger function like:
If table1
if not in table1
raise
else if table2
if not in table2
raise