Re: proposal: catch warnings

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: "Pavel Stehule" <pavel(dot)stehule(at)hotmail(dot)com>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: proposal: catch warnings
Date: 2007-01-07 16:42:34
Message-ID: 13026.1168188154@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

"Pavel Stehule" <pavel(dot)stehule(at)hotmail(dot)com> writes:
> PostgreSQL allow only catch exception (elevel ERROR). SQL/PSM requires that
> warnings are catchable too.

What in the world does it mean to "catch" a warning? If your intention
is to process arbitrary user-defined code while inside the error
subsystem, I can tell you right now that it's unlikely to work.

> Simply solution's is adding one callback to
> error's processing of errors on level WARNING.

I can't get excited about hooks that are defined in such a way that
there can be only one user of the hook ... if it's useful to you,
it's probably useful to someone else too.

regards, tom lane

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2007-01-07 16:47:30 Re: security definer default for some PL languages (SQL/PSM)?
Previous Message Tom Lane 2007-01-07 16:35:06 Re: [HACKERS] SGML index build fix