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

View Issue DetailsJump to Notes ] Issue History ] Print ]
ID
0021426
TypeCategorySeverityReproducibilityDate SubmittedLast Update
defect[Openbravo ERP] A. Platformmajorhave not tried2012-08-23 09:102012-08-29 17:14
ReportermtaalView Statuspublic 
Assigned Tomtaal 
PrioritynormalResolutionfixedFixed in Version3.0MP15
StatusclosedFix in branchFixed in SCM revision83a3b7b37c1d
ProjectionnoneETAnoneTarget Version3.0MP15
OSAnyDatabaseAnyJava version
OS VersionDatabase versionAnt version
Product VersionSCM revision 
Review Assigned Tomarvintm
Web browser
ModulesCore
Regression level
Regression date
Regression introduced in release
Regression introduced by commit
Triggers an Emergency PackNo
Summary

0021426: Adding computed property in a view gives an error in the hibernate mapping

DescriptionWhen adding a property to a view you get an error in the hibernate mapping:

export.database:

export.database.structure:
Initializing in-memory model...
Building runtime model
Model read in-memory, generating mapping...
Error parsing XML (3827) : Attribute "update" was already specified for element "property".
Unable to read XML



The wrong mapping (see the 2 occurrences of the update property):
        <property name="eGOB" access="org.openbravo.dal.core.OBDynamicPropertyHandler" type="java.lang.String" formula="(SELECT CASE WHEN i.posted = 'Y' THEN 'Yes' ELSE 'No' END from
aprm_finacc_transaction_v AS i WHERE i.aprm_finacc_transaction_v_ID =
aprm_finacc_transaction_v_id)" update="false" insert="false" update="false" insert="false"/>


Steps To ReproduceAdd a computed property to a view and then do export.database or another dal related task.

http://wiki.openbravo.com/wiki/How_to_create_a_Computed_Column [^]
TagsNo tags attached.
Attached Files

- Relationships Relation Graph ] Dependency Graph ]

-  Notes
(0051480)
mtaal (manager)
2012-08-23 09:19

Note the module org.openbravo.client.application.example in mercurial adds a computed property to a view for testing this. The view is ProductStockView and the column name is EM_OBEXAPP_productName.
(0051481)
hgbot (developer)
2012-08-23 09:30

Repository: erp/mods/org.openbravo.client.application.examples
Changeset: fab924c3f431ccaa16ea66e8f0d2e1d7334dd5a2
Author: Martin Taal <martin.taal <at> openbravo.com>
Date: Thu Aug 23 09:21:47 2012 +0200
URL: http://code.openbravo.com/erp/mods/org.openbravo.client.application.examples/rev/fab924c3f431ccaa16ea66e8f0d2e1d7334dd5a2 [^]

Related to issue 21426: Adding computed property in a view gives an error in the hibernate mapping
Added computed property to a view for testing this issue

---
M src-db/database/sourcedata/AD_COLUMN.xml
---
(0051482)
hgbot (developer)
2012-08-23 09:30

Repository: erp/devel/pi
Changeset: 83a3b7b37c1d5766a00716d89e7de590c9c2ff52
Author: Martin Taal <martin.taal <at> openbravo.com>
Date: Thu Aug 23 09:29:56 2012 +0200
URL: http://code.openbravo.com/erp/devel/pi/rev/83a3b7b37c1d5766a00716d89e7de590c9c2ff52 [^]

Fixes issue 21426: Adding computed property in a view gives an error in the hibernate mapping
Cleaned up the generation of the update/insert properties in the dalmappinggenerator
so that no clashes occur anymore.

---
M src/org/openbravo/dal/core/DalMappingGenerator.java
---

- Issue History
Date Modified Username Field Change
2012-08-23 09:10 mtaal New Issue
2012-08-23 09:10 mtaal Assigned To => mtaal
2012-08-23 09:10 mtaal Modules => Core
2012-08-23 09:19 mtaal Note Added: 0051480
2012-08-23 09:20 mtaal Closed by => marvintm
2012-08-23 09:30 hgbot Checkin
2012-08-23 09:30 hgbot Note Added: 0051481
2012-08-23 09:30 hgbot Checkin
2012-08-23 09:30 hgbot Note Added: 0051482
2012-08-23 09:30 hgbot Status new => resolved
2012-08-23 09:30 hgbot Resolution open => fixed
2012-08-23 09:30 hgbot Fixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/83a3b7b37c1d5766a00716d89e7de590c9c2ff52 [^]
2012-08-29 17:14 marvintm Status resolved => closed
2012-08-29 17:14 marvintm Fixed in Version => 3.0MP15


Copyright © 2000 - 2009 MantisBT Group
Powered by Mantis Bugtracker