Anonymous | Login
Project:
RSS
  
News | My View | View Issues | Roadmap | Summary

View Issue DetailsJump to Notes ] Issue History ] Print ]
ID
0011189
TypeCategorySeverityReproducibilityDate SubmittedLast Update
defect[Openbravo ERP] A. Platformminoralways2009-10-30 12:342009-11-25 00:00
ReporternetworkbView Statuspublic 
Assigned Tomarvintm 
PriorityimmediateResolutionfixedFixed in Version
StatusclosedFix in branchFixed in SCM revisionadfd8c3d4091
ProjectionnoneETAnoneTarget Version2.50MP10
OSAnyDatabasePostgreSQLJava version
OS VersionDatabase versionAnt version
Product Version2.50MP7SCM revision 
Review Assigned To
Web browser
ModulesCore
Regression level
Regression date
Regression introduced in release
Regression introduced by commit
Triggers an Emergency PackNo
Summary

0011189: Some funcionts raise exceptions in an incorrect way

DescriptionSome funcionts raise exceptions in an incorrect way
The following order is not correct
RAISE EXCEPTION '%',DATA_EXCEPTION;
Steps To ReproduceCreate the following pl:

CREATE OR REPLACE FUNCTION testpl()
  RETURNS void AS
$BODY$
BEGIN
RAISE EXCEPTION '%',DATA_EXCEPTION;
END;
$BODY$
  LANGUAGE 'plpgsql' IMMUTABLE
  COST 100;
ALTER FUNCTION testpl() OWNER TO tad;

Execute the pl:

select testpl();

See that you get an error:
the data_execption column does not exist.

See that the order that fails is used on many procedures and functions. For examplo c_invoice_post:
RAISE EXCEPTION '%',DATA_EXCEPTION;

TagsNo tags attached.
Attached Files

- Relationships Relation Graph ] Dependency Graph ]
has duplicate defect 0011257 closedmarvintm INVOICE POST 

-  Notes
(0021496)
rafaroda (developer)
2009-11-02 05:36

Antonio,

Can you please comment on this issue?

Thanks.
(0021538)
hgbot (developer)
2009-11-03 15:50

Repository: erp/devel/pi
Changeset: adfd8c3d4091b490fcebb21611b0fd778c932bf9
Author: Antonio Moreno <antonio.moreno <at> openbravo.com>
Date: Tue Nov 03 15:45:50 2009 +0100
URL: http://code.openbravo.com/erp/devel/pi/rev/adfd8c3d4091b490fcebb21611b0fd778c932bf9 [^]

Fixed issue 11189. RAISE NO_DATA_FOUND will from now on be translated with quotes in PostgreSQL

---
M src-db/database/lib/dbsourcemanager.jar
---
(0021539)
marvintm (developer)
2009-11-03 15:54

One note: RAISE NO_DATA_FOUND statements should no longer be a problem anymore. However, although statements:

EXCEPTION
   WHEN NO_DATA_FOUND THEN

do not fail in PostgreSQL, it's not clear if the exception is actually raised or not, because apparently NO_DATA_FOUND exceptions are raised differently in PostgreSQL and Oracle. Maybe a refactor of the functions and triggers that use this kind of syntax could be necessary.
(0021710)
rafaroda (developer)
2009-11-11 10:12

Changed target version to 2.50MP10 requested by ECA.

- Issue History
Date Modified Username Field Change
2009-10-30 12:34 networkb New Issue
2009-10-30 12:34 networkb Assigned To => rafaroda
2009-11-02 05:36 rafaroda Note Added: 0021496
2009-11-02 05:36 rafaroda Assigned To rafaroda => marvintm
2009-11-02 05:36 rafaroda Status new => acknowledged
2009-11-02 05:36 rafaroda Issue Monitored: rafaroda
2009-11-03 15:50 hgbot Checkin
2009-11-03 15:50 hgbot Note Added: 0021538
2009-11-03 15:50 hgbot Status acknowledged => resolved
2009-11-03 15:50 hgbot Resolution open => fixed
2009-11-03 15:50 hgbot Fixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/adfd8c3d4091b490fcebb21611b0fd778c932bf9 [^]
2009-11-03 15:54 marvintm Note Added: 0021539
2009-11-05 10:04 marvintm Relationship added has duplicate 0011257
2009-11-11 10:12 rafaroda Note Added: 0021710
2009-11-11 10:12 rafaroda Target Version 2.50MP11 => 2.50MP10
2009-11-24 11:54 dbaz Status resolved => closed
2009-11-25 00:00 anonymous sf_bug_id 0 => 2903420


Copyright © 2000 - 2009 MantisBT Group
Powered by Mantis Bugtracker