Re: WIP: Deferrable unique constraints

From: Alvaro Herrera <alvherre(at)commandprompt(dot)com>
To: Dean Rasheed <dean(dot)a(dot)rasheed(at)googlemail(dot)com>
Cc: Jeff Davis <pgsql(at)j-davis(dot)com>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: WIP: Deferrable unique constraints
Date: 2009-07-20 02:39:51
Message-ID: 20090720023951.GI4938@alvh.no-ip.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Dean Rasheed wrote:
> Thanks for the thorough review. I attach an new version of the patch,
> updated to HEAD, and with the index AM change discussed.

Wow, this is a large patch.

I didn't do a thorough review, but some quickies I noticed:

* Please move the code that says that it should be in a new file to a
new file.

* Please don't mimic the silliness of RI_FKey_check of an unused return
value. Just make it return void, and have the caller use the proper
PG_RETURN_FOO macro. (Unless there's a specific reason to not do
things that way)

* I'm not sure about the changes in trigger.h and related elsewhere.
Seems related to the new list in AfterTriggerSaveEvent, which is
used in ways that seem to conflict with its header comment ... I
wonder if we should be doing that in the executor itself instead.
In any case it's inconsistent that the list is added to
ExecARInsertTriggers but not to ExecARUpdateTrigger et al ...

--
Alvaro Herrera http://www.CommandPrompt.com/
The PostgreSQL Company - Command Prompt, Inc.

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Andrew Dunstan 2009-07-20 02:46:43 Re: conditional dropping of columns/constraints
Previous Message Tom Lane 2009-07-20 01:35:47 Re: [PATCH 1/2 v3] [libpq] rework sigpipe-handling macros