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

View Issue DetailsJump to Notes ] Issue History ] Print ]
ID
0011971
TypeCategorySeverityReproducibilityDate SubmittedLast Update
defect[Openbravo ERP] A. Platformminoralways2010-01-14 19:002010-04-19 21:11
ReportericiordiaView Statuspublic 
Assigned Tomarvintm 
PriorityurgentResolutionfixedFixed in Version2.50MP15
StatusclosedFix in branchFixed in SCM revision6729e5065a3c
ProjectionnoneETAnoneTarget Version
OSAnyDatabaseAnyJava versionany
OS VersionanyDatabase versionanyAnt versionany
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

0011971: Exporting a PL/Sql object in a postgreSql database and importing it results in a different object

DescriptionWhen DBSourceManager reads database objects in a postgresql database it modifies the code to make it compatible with oracle. Then, when importing into a postgresql database, the system modify back the code (do changes in opposite manner) to get the original code.

But not all pl/sql code in postgresql is supported. In some cases this transformation fail and the result after export/import is diferent from the original, without any warning from the system.
Steps To ReproduceRunning Openbravo in a postgresql database, create a new function with return type TABLE (RETURNS TABLE). Export it using ant export.database. Then import it using ant update.database -> the result is that return type of the function is removed.
Proposed SolutionWhen DBSourceManager exports a pl/sql object in a postgresql database, perform the following validation: apply transformation back to the exported code and compare it with the original object (both should be identical but blank spaces and upper/lower case differences)
TagsNo tags attached.
Attached Files

- Relationships Relation Graph ] Dependency Graph ]

-  Notes
(0025675)
hgbot (developer)
2010-03-23 16:18

Repository: erp/devel/pi
Changeset: 6729e5065a3c1e8a33df7b583cd760ab9f5b7bae
Author: Antonio Moreno <antonio.moreno <at> openbravo.com>
Date: Tue Mar 23 16:25:23 2010 +0100
URL: http://code.openbravo.com/erp/devel/pi/rev/6729e5065a3c1e8a33df7b583cd760ab9f5b7bae [^]

Fixed issue 11971. A check will be done to verify that the exported functions and triggers will not change when imported again in PostgreSQL. A warning will be given in case some of the objects do not comply with this check.

---
M src-db/database/build.xml
M src-db/database/lib/dbsourcemanager.jar
---
(0025685)
hgbot (developer)
2010-03-23 18:55

Repository: erp/devel/pi
Changeset: 3725f0e49097b08b46d5c73cfa69daebe589f00a
Author: Antonio Moreno <antonio.moreno <at> openbravo.com>
Date: Tue Mar 23 19:02:17 2010 +0100
URL: http://code.openbravo.com/erp/devel/pi/rev/3725f0e49097b08b46d5c73cfa69daebe589f00a [^]

Related to issue 11971. Added the checkTranslationConsistency property to the main build.xml

---
M build.xml
---
(0025696)
hgbot (developer)
2010-03-24 10:06

Repository: erp/devel/pi
Changeset: f7108cede5435be7e8329f9136a4839366ad3ef0
Author: Antonio Moreno <antonio.moreno <at> openbravo.com>
Date: Wed Mar 24 10:15:00 2010 +0100
URL: http://code.openbravo.com/erp/devel/pi/rev/f7108cede5435be7e8329f9136a4839366ad3ef0 [^]

Related to issue 11971. Improved the log: now a diff of the two versions of the function or trigger will be shown, so that the developer knows more precisely what he needs to fix.

---
M src-db/database/lib/dbsourcemanager.jar
---
(0026069)
shuehner (administrator)
2010-04-12 16:27

Tested in pi on both oracle/postgres. Having database code without any consistency issues the export works as before. Introducing some code into the postgres-db which cannot be properly translated to xml and back to pgsql, or code on oracle which cannot be properly translated to postgres raise a warning in the export.database output, which shows the function name and a short diff of the change which would happen.
However only the warning is shown and the export.db continues (as planned).

-> Closing as working fine.
(0026373)
hudsonbot (developer)
2010-04-19 21:10

A changeset related to this issue has been promoted to main after passing a series of tests and an OBX has been generated:

Changeset: http://code.openbravo.com/erp/devel/main/rev/6729e5065a3c [^]
Merge Changeset: http://code.openbravo.com/erp/devel/main/rev/91d98bda46c1 [^]
Tests: http://builds.openbravo.com/view/devel-int/ [^]
OBX: http://builds.openbravo.com/erp/core/obx/OpenbravoERP-2.50CI.17088.obx [^]
(0026374)
hudsonbot (developer)
2010-04-19 21:11

A changeset related to this issue has been promoted to main after passing a series of tests and an OBX has been generated:

Changeset: http://code.openbravo.com/erp/devel/main/rev/3725f0e49097 [^]
Merge Changeset: http://code.openbravo.com/erp/devel/main/rev/91d98bda46c1 [^]
Tests: http://builds.openbravo.com/view/devel-int/ [^]
OBX: http://builds.openbravo.com/erp/core/obx/OpenbravoERP-2.50CI.17088.obx [^]
(0026378)
hudsonbot (developer)
2010-04-19 21:11

A changeset related to this issue has been promoted to main after passing a series of tests and an OBX has been generated:

Changeset: http://code.openbravo.com/erp/devel/main/rev/f7108cede543 [^]
Merge Changeset: http://code.openbravo.com/erp/devel/main/rev/91d98bda46c1 [^]
Tests: http://builds.openbravo.com/view/devel-int/ [^]
OBX: http://builds.openbravo.com/erp/core/obx/OpenbravoERP-2.50CI.17088.obx [^]

- Issue History
Date Modified Username Field Change
2010-01-14 19:00 iciordia New Issue
2010-01-14 19:00 iciordia Assigned To => marvintm
2010-01-14 19:01 iciordia Status new => scheduled
2010-01-14 19:01 iciordia fix_in_branch => pi
2010-03-08 16:06 jpabloae Target Version 2.50MP13 => 2.50MP14
2010-03-15 10:03 marvintm Target Version 2.50MP14 =>
2010-03-15 10:03 marvintm fix_in_branch pi =>
2010-03-23 16:18 hgbot Checkin
2010-03-23 16:18 hgbot Note Added: 0025675
2010-03-23 16:18 hgbot Status scheduled => resolved
2010-03-23 16:18 hgbot Resolution open => fixed
2010-03-23 16:18 hgbot Fixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/6729e5065a3c1e8a33df7b583cd760ab9f5b7bae [^]
2010-03-23 18:55 hgbot Checkin
2010-03-23 18:55 hgbot Note Added: 0025685
2010-03-24 10:06 hgbot Checkin
2010-03-24 10:06 hgbot Note Added: 0025696
2010-04-12 16:27 shuehner Note Added: 0026069
2010-04-12 16:27 shuehner Status resolved => closed
2010-04-12 16:27 shuehner Fixed in Version => 2.50MP15
2010-04-13 00:00 anonymous sf_bug_id 0 => 2986149
2010-04-19 21:10 hudsonbot Checkin
2010-04-19 21:10 hudsonbot Note Added: 0026373
2010-04-19 21:11 hudsonbot Checkin
2010-04-19 21:11 hudsonbot Note Added: 0026374
2010-04-19 21:11 hudsonbot Checkin
2010-04-19 21:11 hudsonbot Note Added: 0026378


Copyright © 2000 - 2009 MantisBT Group
Powered by Mantis Bugtracker