Re: RI triggers and schemas - Mailing list pgsql-hackers

From Christopher Kings-Lynne
Subject Re: RI triggers and schemas
Date
Msg-id 20020401120549.F88727-100000@houston.familyhealth.com.au
Whole thread Raw
In response to Re: RI triggers and schemas  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: RI triggers and schemas  (Tom Lane <tgl@sss.pgh.pa.us>)
Re: RI triggers and schemas  (Jan Wieck <janwieck@yahoo.com>)
List pgsql-hackers
> I've just realized that if we change the RI trigger arguments this way,
> we will have a really serious problem with accepting pg_dump scripts
> from prior versions.  The scripts' representation of foreign key
> constraints will contain commands like
>
> CREATE CONSTRAINT TRIGGER "<unnamed>" AFTER UPDATE ON "bar"  FROM "baz" NOT DEFERRABLE INITIALLY IMMEDIATE FOR EACH
ROWEXECUTE PROCEDURE "RI_FKey_noaction_upd" ('<unnamed>', 'baz', 'bar', 'UNSPECIFIED', 'f1', 'f1');
 
>
> which will absolutely not work at all if the 7.3 triggers are expecting
> to find OIDs in those arguments.

Why can't we just hack up the CREATE CONSTRAINT TRIGGER code to look up
the OIDs, etc. for the arguments and convert them internally to an ALTER
TABLE/ADD CONSTRAINT or whatever...

Chris




pgsql-hackers by date:

Previous
From: "Rod Taylor"
Date:
Subject: Re: RI triggers and schemas
Next
From: Tom Lane
Date:
Subject: Re: RI triggers and schemas