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

View Issue DetailsJump to Notes ] Issue History ] Print ]
ID
0010709
TypeCategorySeverityReproducibilityDate SubmittedLast Update
defect[Openbravo ERP] A. Platformmajoralways2009-09-23 10:542009-10-22 00:00
ReportersathiyanView Statuspublic 
Assigned Tomarvintm 
PriorityurgentResolutionfixedFixed in Version
StatusclosedFix in branchFixed in SCM revision178bd53e1b9b
ProjectionnoneETAnoneTarget Version
OSLinux 32 bitDatabasePostgreSQLJava version1.6
OS VersionUbuntu 9.04Database versionPostgreSQL 8.3.5Ant version1.7
Product VersionpiSCM revision 
Review Assigned To
Web browser
ModulesCore
Regression level
Regression date
Regression introduced in release
Regression introduced by commit
Triggers an Emergency PackNo
Summary

0010709: variable is misinterpreted by DBSource Manager if variable name with suffix TYPE

Descriptionif we use the variable name with suffix of TYPE, For instance the variable name in our trigger is EM_ACCDEF_TYPE, It is interpreted like EM_ACCDEF_--TYPE when we apply ant task of update.database (or install.source).

We have attached trigger xml (ACCDEF_INVOICE_TRG.xml).

The complete code of interpreted by dbsourcemanager:

 CREATE FUNCTION ACCDEF_INVOICE_TRG()
RETURNS trigger
AS $BODY$ DECLARE

BEGIN
    IF AD_isTriggerEnabled()='N' THEN IF TG_OP = 'DELETE' THEN RETURN OLD; ELSE RETURN NEW; END IF;
    END IF;
        IF TG_OP = 'UPDATE' THEN
     IF(OLD.DOCSTATUS='CO' AND (OLD.EM_ACCDEF_--TYPE IS NULL AND NEW.EM_ACCDEF_TYPE IS NOT NULL) OR (OLD.EM_ACCDEF_TYPE IS NOT NULL AND NEW.EM_ACCDEF_TYPE IS NULL)) THEN
                        RAISE EXCEPTION '%', 'Document processed/posted'; --OBTG:-20501--
         END IF;
       
        END IF;
        IF TG_OP = 'DELETE' THEN
                IF(OLD.DOCSTATUS='CO') THEN
                        RAISE EXCEPTION '%', 'Document processed/posted'; --OBTG:-20501--
                END IF;
        END IF;
IF TG_OP = 'DELETE' THEN RETURN OLD; ELSE RETURN NEW; END IF;
Proposed SolutionRefine regular expresion to require a blank space before the 'type'
TagsNo tags attached.
Attached Filesxml file icon ACCDEF_INVOICE_TRG.xml [^] (773 bytes) 2009-09-23 10:54

- Relationships Relation Graph ] Dependency Graph ]

-  Notes
(0020394)
hgbot (developer)
2009-09-28 11:53

Repository: erp/devel/pi
Changeset: 178bd53e1b9b8dce1afe03e408236ed9cf8a4fa1
Author: Antonio Moreno <antonio.moreno <at> openbravo.com>
Date: Fri Sep 25 17:47:39 2009 +0200
URL: http://code.openbravo.com/erp/devel/pi/rev/178bd53e1b9b8dce1afe03e408236ed9cf8a4fa1 [^]

Fixed issue 10709. It should be possible now to use the word TYPE in PL/SQL without trouble, in PostgreSQL

---
M src-db/database/lib/dbsourcemanager.jar
---
(0020519)
hgbot (developer)
2009-09-29 14:18

Repository: erp/devel/pi-pageddatagrid
Changeset: 178bd53e1b9b8dce1afe03e408236ed9cf8a4fa1
Author: Antonio Moreno <antonio.moreno <at> openbravo.com>
Date: Fri Sep 25 17:47:39 2009 +0200
URL: http://code.openbravo.com/erp/devel/pi-pageddatagrid/rev/178bd53e1b9b8dce1afe03e408236ed9cf8a4fa1 [^]

Fixed issue 10709. It should be possible now to use the word TYPE in PL/SQL without trouble, in PostgreSQL

---
M src-db/database/lib/dbsourcemanager.jar
---

- Issue History
Date Modified Username Field Change
2009-09-23 10:54 sathiyan New Issue
2009-09-23 10:54 sathiyan Assigned To => rafaroda
2009-09-23 10:54 sathiyan File Added: ACCDEF_INVOICE_TRG.xml
2009-09-23 12:43 iciordia Assigned To rafaroda => marvintm
2009-09-23 12:45 iciordia Priority normal => urgent
2009-09-23 12:45 iciordia Steps to Reproduce Updated
2009-09-23 15:20 shuehner Issue Monitored: shuehner
2009-09-28 11:53 hgbot Checkin
2009-09-28 11:53 hgbot Note Added: 0020394
2009-09-28 11:53 hgbot Status new => resolved
2009-09-28 11:53 hgbot Resolution open => fixed
2009-09-28 11:53 hgbot Fixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/178bd53e1b9b8dce1afe03e408236ed9cf8a4fa1 [^]
2009-09-29 14:18 hgbot Checkin
2009-09-29 14:18 hgbot Note Added: 0020519
2009-09-29 14:18 hgbot Fixed in SCM revision http://code.openbravo.com/erp/devel/pi/rev/178bd53e1b9b8dce1afe03e408236ed9cf8a4fa1 [^] => http://code.openbravo.com/erp/devel/pi-pageddatagrid/rev/178bd53e1b9b8dce1afe03e408236ed9cf8a4fa1 [^]
2009-10-21 15:26 plujan Status resolved => closed
2009-10-22 00:00 anonymous sf_bug_id 0 => 2883559


Copyright © 2000 - 2009 MantisBT Group
Powered by Mantis Bugtracker