From: Tom Lane <tgl@sss.pgh.pa.us>
To: Karthikeyan Sundaram <skarthi98@hotmail.com>
Cc: pgsql-admin@postgresql.org
Cc: pgsql-sql@postgresql.org
Subject: Re: [SQL] exception handling in postgres plpgsql
Date: Tue, 03 Apr 2007 20:24:12 -0400
Message-ID: <14030.1175646252@sss.pgh.pa.us> (raw)
In-Reply-To: <BAY131-W11D9F51A1A2E1E3AEFB6D8B0670@phx.gbl>
References: <BAY131-W11D9F51A1A2E1E3AEFB6D8B0670@phx.gbl>
Karthikeyan Sundaram <skarthi98@hotmail.com> writes:
> When I compile, I am getting an error message
> ERROR: unrecognized exception condition "no_data_found"CONTEXT: compile o=
> f PL/pgSQL function "audio_format_func" near line 15
> =20
> How will I handle exceptions in postgres?
Reading between the lines I gather that you are reading 8.2
documentation and trying to apply the info to some previous version that
doesn't have SELECT INTO STRICT (which you failed to use anyway...)
You probably want to test the magic FOUND variable instead --- see the
plpgsql docs.
regards, tom lane
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-sql@postgresql.org
Cc: tgl@sss.pgh.pa.us, skarthi98@hotmail.com, pgsql-admin@postgresql.org
Subject: Re: [SQL] exception handling in postgres plpgsql
In-Reply-To: <14030.1175646252@sss.pgh.pa.us>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox