Re: enhanced error fields - Mailing list pgsql-hackers

From Peter Geoghegan
Subject Re: enhanced error fields
Date
Msg-id CAEYLb_XHJdqD9o1uz__GjnVhUB302-SAwZUJh-qo_0PpCmxWkg@mail.gmail.com
Whole thread Raw
In response to Re: enhanced error fields  (Peter Eisentraut <peter_e@gmx.net>)
Responses Re: enhanced error fields
List pgsql-hackers
On 28 January 2013 21:33, Peter Eisentraut <peter_e@gmx.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
ROUTINE_NAME.

-- 
Regards,
Peter Geoghegan



pgsql-hackers by date:

Previous
From: Steve Singer
Date:
Subject: Re: logical changeset generation v4 - Heikki's thoughts about the patch state
Next
From: Steve Singer
Date:
Subject: Re: logical changeset generation v4