BUG #5310: "NOT FOUND" throws "GetData to Procedure return failed." in stored functions
| От | Lothar Bongartz |
|---|---|
| Тема | BUG #5310: "NOT FOUND" throws "GetData to Procedure return failed." in stored functions |
| Дата | |
| Msg-id | 201002031614.o13GESkb075957@wwwmaster.postgresql.org обсуждение исходный текст |
| Ответы |
Re: BUG #5310: "NOT FOUND" throws "GetData to Procedure return
failed." in stored functions
Re: BUG #5310: "NOT FOUND" throws "GetData to Procedure return failed." in stored functions |
| Список | pgsql-bugs |
The following bug has been logged online:
Bug reference: 5310
Logged by: Lothar Bongartz
Email address: lotharbongartz@hotmail.com
PostgreSQL version: 8.4
Operating system: Windows XP Professioanl
Description: "NOT FOUND" throws "GetData to Procedure return failed."
in stored functions
Details:
A "NOT FOUND" condition in a stored function throws a "GetData to Procedure
return failed." error, which cannot be trapped by the EXCEPTION handling.
Example:
SELECT msg_id INTO v_nm FROM newmail WHERE memb_id=v_id;
The only way to avoid the complete failing of the stored function is to do a
check before:
IF EXISTS (SELECT * FROM newmail WHERE memb_id=v_id) THEN
SELECT msg_id INTO v_nm FROM newmail WHERE memb_id=v_id;
END IF;
В списке pgsql-bugs по дате отправления: