Skip site navigation (1) Skip section navigation (2)

Re: enhanced error fields

From: Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
To: Peter Geoghegan <peter(dot)geoghegan86(at)gmail(dot)com>
Cc: Peter Eisentraut <peter_e(at)gmx(dot)net>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, "anarazel(at)anarazel(dot)de" <andres(at)anarazel(dot)de>, Robert Haas <robertmhaas(at)gmail(dot)com>, Stephen Frost <sfrost(at)snowman(dot)net>, PostgreSQL Hackers <pgsql-hackers(at)postgresql(dot)org>, Alvaro Herrera <alvherre(at)commandprompt(dot)com>
Subject: Re: enhanced error fields
Date: 2013-01-29 17:05:42
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-hackers
2013/1/28 Peter Geoghegan <peter(dot)geoghegan86(at)gmail(dot)com>:
> On 28 January 2013 21:33, Peter Eisentraut <peter_e(at)gmx(dot)net> wrote:
>> Another point, in case someone wants to revisit this in the future, is
>> that these fields were applied in a way that is contrary to the SQL
>> standard, I think.
>> The presented patch interpreted ROUTINE_NAME as: the error happened
>> while executing this function.  But according to the standard, the field
>> is only set when the error was directly related to the function itself,
>> for example when calling an INSERT statement in a non-volatile function.
> Right. It seems to me that ROUTINE_NAME is vastly less compelling than
> the fields that are likely to be present in the committed patch. GET
> DIAGNOSTICS, as implemented by DB2, allows clients /to poll/ for a
> large number of fields. I'm not really interested in that myelf, but
> if we were to add something in the same spirit, I think that extending
> errdata to support this would not be a sensible approach.
> Perhaps I'm mistaken, but I can't imagine that it would be terribly
> useful to anyone (including Pavel) to have a GET DIAGNOSTICS style

I hoped so I can use it inside exception handler



> --
> Regards,
> Peter Geoghegan

In response to


pgsql-hackers by date

Next:From: Peter GeogheganDate: 2013-01-29 17:13:52
Subject: Re: enhanced error fields
Previous:From: Christopher BrowneDate: 2013-01-29 17:04:11
Subject: Re: Event Triggers: adding information

Privacy Policy | About PostgreSQL
Copyright © 1996-2018 The PostgreSQL Global Development Group