Re: rename constraint behavior for duplicate names?

From: Allan Wang <allanvv(at)gmail(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: rename constraint behavior for duplicate names?
Date: 2005-09-01 22:04:23
Message-ID: 1125612263.15631.19.camel@localhost
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Thu, 2005-09-01 at 17:55 -0400, Tom Lane wrote:
> Allan Wang <allanvv(at)gmail(dot)com> writes:
> > Alright, I see why the checks are still needed. The unique index should
> > be on relname, conname right? Also looking into DROP CONSTRAINT's code,
> > it gives a notice about "multiple constraint names dropped" when
> > RemoveRelConstraints(rel, conname) returns > 1. This check isn't needed
> > anymore right? Also RemoveRelConstraints can be simplified to assume
> > only one row will need removing, and be turned into a void function?
>
> Not unless you want to break the "quiet" option for ATExecDropConstraint.

Is the quiet option supposed to work anyway other than suppressing the
not exists error? Since there can't be multiple constraint names the
notice is never executed anyway. Otherwise I don't see how it would
break. (It would still be used for suppressing the not-exists error)

Allan Wang

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2005-09-01 22:06:36 Re: rename constraint behavior for duplicate names?
Previous Message Tom Lane 2005-09-01 21:55:14 Re: rename constraint behavior for duplicate names?