| From: | David Rowley <david(dot)rowley(at)2ndquadrant(dot)com> |
|---|---|
| To: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
| Cc: | Alvaro Herrera <alvherre(at)2ndquadrant(dot)com>, Ash M <makmarath(at)hotmail(dot)com>, PostgreSQL mailing lists <pgsql-bugs(at)lists(dot)postgresql(dot)org> |
| Subject: | Re: BUG #15572: Misleading message reported by "Drop function operation" on DB with functions having same name |
| Date: | 2019-01-15 23:38:55 |
| Message-ID: | CAKJS1f-2-wVsN5zXaKWdp4xOUkkstnoPo0Lis6RQ=AEo3_pcig@mail.gmail.com |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-bugs pgsql-hackers |
On Wed, 9 Jan 2019 at 13:36, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
>
> David Rowley <david(dot)rowley(at)2ndquadrant(dot)com> writes:
> > Why can't we just remove the !noError check in the location where the
> > error is raised?
>
> I don't like that a bit --- the point of noError is to prevent throwing
> errors, and it doesn't seem like it should be LookupFuncName's business
> to decide it's smarter than its callers. Maybe we need another flag
> argument?
Well, I guess you didn't have backpatching this in mind. The reason I
thought it was okay to hijack that flag was that the ambiguous error
was only raised when the function parameters were not defined. I
chased around and came to the conclusion this only happened during
DROP. Maybe that's a big assumption as it certainly might not help
future callers passing nargs as -1.
I've attached another version with a newly added flag.
--
David Rowley http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Training & Services
| Attachment | Content-Type | Size |
|---|---|---|
| drop_func_if_not_exists_fix_v2.patch | application/octet-stream | 17.7 KB |
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Michael Paquier | 2019-01-16 01:36:33 | Re: Is temporary functions feature official/supported? Found some issues with it. |
| Previous Message | Alvaro Herrera | 2019-01-15 22:55:56 | Re: BUG #15587: Partitions with ALTER TABLE ADD CONSTRAINT |
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Tomas Vondra | 2019-01-16 00:23:41 | Re: [PROPOSAL] Shared Ispell dictionaries |
| Previous Message | Tom Lane | 2019-01-15 22:35:21 | Re: Why are we PageInit'ing buffers in RelationAddExtraBlocks()? |