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

BUG #5524: SQLSTATE exception thrown from exception handling block prevents plpgsql function from compiling

From: "Peter Gagarinov" <pgagarinov(at)alliedtesting(dot)com>
To: pgsql-bugs(at)postgresql(dot)org
Subject: BUG #5524: SQLSTATE exception thrown from exception handling block prevents plpgsql function from compiling
Date: 2010-06-25 13:35:05
Message-ID: 201006251335.o5PDZ5If070540@wwwmaster.postgresql.org (view raw or flat)
Thread:
Lists: pgsql-bugs
The following bug has been logged online:

Bug reference:      5524
Logged by:          Peter Gagarinov
Email address:      pgagarinov(at)alliedtesting(dot)com
PostgreSQL version: 9.0 Beta 2
Operating system:   Windows XP Professional SP2
Description:        SQLSTATE exception thrown from exception handling block
prevents plpgsql function from compiling
Details: 

The following function doesn’t seem to compile in PostgreSQL 9.0 while 8.4
accepts it with no problem.

CREATE OR REPLACE FUNCTION test.delete_sessions()
  RETURNS void AS
$BODY$
BEGIN
select 1;
EXCEPTION WHEN SQLSTATE '55P03' THEN
               RAISE SQLSTATE '55P03' using MESSAGE ='test message';
END
$BODY$
  LANGUAGE 'plpgsql' VOLATILE
  COST 100;

Responses

pgsql-bugs by date

Next:From: Tom LaneDate: 2010-06-25 16:40:47
Subject: Re: BUG #5524: SQLSTATE exception thrown from exception handling block prevents plpgsql function from compiling
Previous:From: pgagarinovDate: 2010-06-25 13:31:52
Subject: SQLSTATE exception thrown from exception handling block prevents plpgsql function from compiling

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