Re: How to replace rows in table so that foreign key rows - Mailing list pgsql-general

From Stephan Szabo
Subject Re: How to replace rows in table so that foreign key rows
Date
Msg-id 20060421073219.J12604@megazone.bigpanda.com
Whole thread Raw
In response to Re: How to replace rows in table so that foreign key rows  ("Andrus" <eetasoft@online.ee>)
List pgsql-general
On Fri, 21 Apr 2006, Andrus wrote:

> > ... and there doesn't appear (for
> > non-match partial constraints) seem to be a special case for the
> > referenced row coming back into existance as far as I can tell either.
>
> > Or, if you're willing to patch, I think a first order approximation of
> > what you want might be to remove the special cases in trigger.c
> > (afterTriggerSetState) and tablecmds.c (createForeignKeyTriggers), but I
> > haven't tested that.
>
> Thank you.
> So I must create and maintain special version of PostgreSQL ?

If the standard does say it should do what you want, it'll get changed for
a later version, but probably not backpatched, so this would be a short
term solution. The hardest part about changing it is making sure there
aren't any new holes in the constraint.

If the standard doesn't match what you want, then it's a bit more
involved. Following the standard would still require you to maintain
a special version for the rules you want or changing the expectation. Or,
alternatively, you could make a case why the standard does say what you
want (or allows what you want or is simply wrong) if there's a
disagreement.

pgsql-general by date:

Previous
From: Mark Sargent
Date:
Subject: Re: psql: FATAL: missing or erroneous pg_hba.conf file
Next
From: Tom Lane
Date:
Subject: Re: psql: FATAL: missing or erroneous pg_hba.conf file