Re: ENABLE/DISABLE CONSTRAINT NAME

From: wangshuo(at)highgo(dot)com(dot)cn
To: Robert Haas <robertmhaas(at)gmail(dot)com>, Jim Nasby <jim(at)nasby(dot)net>
Cc: Peter Eisentraut <peter_e(at)gmx(dot)net>, Bernd Helmle <mailings(at)oopsware(dot)de>, David Johnston <polobo(at)yahoo(dot)com>, Pgsql Hackers <pgsql-hackers(at)postgresql(dot)org>, Jeff Davis <pgsql(at)j-davis(dot)com>
Subject: Re: ENABLE/DISABLE CONSTRAINT NAME
Date: 2013-10-11 01:44:20
Message-ID: 3f7951c11d3fa4685a32b0ed89c5025d@highgo.com.cn
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On 2013-10-10 02:10, Robert Haas wrote:

> I agree with these concerns, as well as those raised by Tom Lane and
> Fabien COELHO, and I think they indicate that we shouldn't accept
> this
> patch. So I'm marking this as Rejected.

On 2013-10-11 06:48, Jim Nasby wrote:

>I see a use case for disabling FKs and CHECKS but not PKs or UNIQUE
> constraints: FKs and CHECKS don't depend on additional state
> information (namely an index), so >it's easy to just disable them
> temporarily and then re-enable them. The same isn't true about a PK or
> UNIQUE constraint.
>
>Of course we could decide to do something more complex to handle
> disabling PK/UNIQUE... though at that point it'd be better to just
> allow temporarily disabling >any index. But I think there's an argument
> to be made for that being beyond the scope of disabling "simple"
> constraints... it's a pretty high bar to set that we ?>won't accept a
> patch that disables simple constraints but not those involving indexes.

Thanks for your reply.
I found my patch's weakness.I think the DISABLE/ENABLE patch is
necessary.
I will pack a new patch for all the constraints to commit.
Thanks again.

Yours,
Wang Shuo
HighGo Software Co.,Ltd.
October 11, 2013

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Robert Haas 2013-10-11 01:52:21 Re: [COMMITTERS] pgsql: Replace duplicate_oids with Perl implementation
Previous Message Peter Eisentraut 2013-10-11 01:37:24 Re: Bugfix and new feature for PGXS