Re: exception handling in plpgsql

From: Korry <korry(at)starband(dot)net>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: exception handling in plpgsql
Date: 2005-01-02 00:30:08
Message-ID: 1104625808.7784.4.camel@sakai
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Sat, 2005-01-01 at 14:10 -0500, Tom Lane wrote:

> Korry <korry(at)starband(dot)net> writes:
> > It seems you can’t trap every condition listed in errocodes-
> > appendix.html; in particular, you can’t trap SUCCESSFUL_COMPLETION, any
> > of the conditions listed in the WARNING category, or any of the
> > conditions listed in the NO DATA category. (At least through 8.0 rc1 -
> > I haven't checked in later versions).
>
> Those aren't errors.

Right. Just trying to clarify the issue for the person that asked the
question.

The pl/pgSQL documentation (37.7.5) says:

> The condition names can be any of those shown in Appendix A.

As you say, not all of the conditions listed in Appendix A are error
conditions. Perhaps 37.7.5 should be changed to clarify? Without
looking at plerrcodes.h, you can't find a definitive list.

-- Korry

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Bruce Momjian 2005-01-02 06:02:09 Re: [HACKERS] Bgwriter behavior
Previous Message Simon Riggs 2005-01-01 21:30:13 Re: 'COPY ... FROM' inserts to btree, blocks on buffer