Openbravo Issue Tracking System - Openbravo ERP
View Issue Details
0012856Openbravo ERP03. Procurement managementpublic2010-03-31 16:462010-06-07 23:43
adrianromero 
adrianromero 
urgentmajoralways
closedfixed 
5
2.40MP12 
2.40MP13 
Core
No
0012856: Error in 'Purchase Order Report'
When we want to create a Purchase Order Report with a currency different from EURO, this error appears:

Error executing SQL statement for : ReportPurchaseOrder
- Go to Procurement Management || Analysis Tools || Purchase Order Report
- Currency: USD and click 'Ok'
No tags attached.
blocks defect 00128182.40MP13 closed adrianromero Error in 'Purchase Order Report' 
jpg POReport.JPG (167,617) 2010-04-26 09:35
https://issues.openbravo.com/file_download.php?file_id=2479&type=bug
jpg
Issue History
2010-03-31 16:46adrianromeroNew Issue
2010-03-31 16:46adrianromeroAssigned To => adrianromero
2010-03-31 16:46adrianromeroIssue generated from0012818
2010-03-31 16:46adrianromeroRelationship addedblocks 0012818
2010-03-31 16:47adrianromeroStatusnew => scheduled
2010-03-31 16:47adrianromerofix_in_branch => pi
2010-04-20 17:46adrianromeroNote Added: 0026519
2010-04-20 17:46adrianromeroResolutionopen => fixed
2010-04-20 17:46adrianromeroFixed in SCM revision => http://code.openbravo.com/erp/stable/2.40/rev/4110117ac7c437640eba5f95aed3113245b45e63 [^]
2010-04-20 17:46adrianromerofix_in_branchpi =>
2010-04-20 17:46adrianromeroStatusscheduled => resolved
2010-04-26 09:35arunkumarNote Added: 0026670
2010-04-26 09:35arunkumarStatusresolved => new
2010-04-26 09:35arunkumarResolutionfixed => open
2010-04-26 09:35arunkumarFile Added: POReport.JPG
2010-04-26 11:57adrianromeroStatusnew => scheduled
2010-04-26 11:57adrianromerofix_in_branch => pi
2010-04-26 15:11hgbotCheckin
2010-04-26 15:11hgbotNote Added: 0026679
2010-04-26 15:11hgbotStatusscheduled => resolved
2010-04-26 15:11hgbotResolutionopen => fixed
2010-04-26 15:11hgbotFixed in SCM revisionhttp://code.openbravo.com/erp/stable/2.40/rev/4110117ac7c437640eba5f95aed3113245b45e63 [^] => http://code.openbravo.com/erp/devel/pi/rev/19f1bedbb5caa79ee914b4824633b874a4720b61 [^]
2010-04-26 15:22adrianromeroNote Added: 0026680
2010-04-26 15:28adrianromeroNote Deleted: 0026680
2010-04-26 15:28adrianromeroNote Deleted: 0026679
2010-04-26 15:31hgbotCheckin
2010-04-26 15:31hgbotNote Added: 0026684
2010-04-26 15:31hgbotFixed in SCM revisionhttp://code.openbravo.com/erp/devel/pi/rev/19f1bedbb5caa79ee914b4824633b874a4720b61 [^] => http://code.openbravo.com/erp/stable/2.40/rev/6c9d1965d414be51a917136718930b92e959c915 [^]
2010-04-26 15:32adrianromeroNote Added: 0026685
2010-04-28 07:52sureshbabuNote Added: 0026736
2010-04-28 07:56sureshbabuNote Edited: 0026736bug_revision_view_page.php?bugnote_id=0026736#r290
2010-04-28 08:02sureshbabuNote Edited: 0026736bug_revision_view_page.php?bugnote_id=0026736#r291
2010-05-14 15:28hudsonbotCheckin
2010-05-14 15:28hudsonbotNote Added: 0027298
2010-05-17 07:54sureshbabuNote Added: 0027345
2010-05-17 07:54sureshbabuStatusresolved => closed
2010-06-04 14:46hgbotCheckin
2010-06-04 14:46hgbotNote Added: 0027991
2010-06-04 14:46hgbotStatusclosed => resolved
2010-06-04 14:46hgbotFixed in SCM revisionhttp://code.openbravo.com/erp/stable/2.40/rev/6c9d1965d414be51a917136718930b92e959c915 [^] => http://code.openbravo.com/erp/devel/pi/rev/07551d9c00f2f5e31ca771c18d8678ab3fe06a73 [^]
2010-06-07 11:40arunkumarNote Added: 0028045
2010-06-07 11:40arunkumarStatusresolved => closed
2010-06-07 21:21hudsonbotCheckin
2010-06-07 21:21hudsonbotNote Added: 0028113
2010-06-07 23:43hudsonbotCheckin
2010-06-07 23:43hudsonbotNote Added: 0028155

Notes
(0026519)
adrianromero   
2010-04-20 17:46   
Repository: erp/stable/2.40
Changeset: 4110117ac7c437640eba5f95aed3113245b45e63
Author: Adrián Romero <adrianromero <at> openbravo.com>
Date: Tue Apr 20 17:53:39 2010 +0200
URL: http://code.openbravo.com/erp/stable/2.40/rev/4110117ac7c437640eba5f95aed3113245b45e63 [^] [^]

Fixes issue 12818: Error in Purchase Order Report

---
M src/org/openbravo/base/secureApp/HttpSecureAppServlet.java
---
(0026670)
arunkumar   
2010-04-26 09:35   
When I retested this issue in 2.40 oracle I have got an error message "literal does not match format string". (Refer the screenshot attached)

2.40 postgres works fine with the fix.
(0026684)
hgbot   
2010-04-26 15:31   
Repository: erp/stable/2.40
Changeset: 6c9d1965d414be51a917136718930b92e959c915
Author: Adrián Romero <adrianromero <at> openbravo.com>
Date: Mon Apr 26 15:31:38 2010 +0200
URL: http://code.openbravo.com/erp/stable/2.40/rev/6c9d1965d414be51a917136718930b92e959c915 [^]

Fixes issue 0012856: Error in 'Purchase Order Report'

---
M src/org/openbravo/erpCommon/ad_reports/ReportPurchaseOrder.jrxml
---
(0026685)
adrianromero   
2010-04-26 15:32   
* Testing of the issue:
To test the issue just follow the steps to reproduce and execute the report with a currency different than EUR. Try to execute the report several times using different "Starting date" and "Ending date" values. The error message should always be similar to: There is no conversion rate defined from (EUR-€) to (USD-$) for date '07-08-2006', Client 'SmallBazaar' and Organization 'Main'.

* Explanation of the changeset that fixes the issue:
There has been modified the File HttpSecureAppServlet.java to get the causeException message instead of the JasperError Exception message. This is because the real message of the exception is in the causeException object.
It has been modified too the report template ReportPurchaseOrder.jrxml adding the function TO_DATE to the date parameters of the report to make the report work properly in Oracle and Postgresql.

* Other areas affected by the changeset:
The changes in the report template only affects to this report. And the changes in HttpSecureAppServlet.java affects to all jasper reports that throw an exception. The change is done the way if the causeException is an SQLException then use the SQLException message. That is the correct message that has to be translated and displayed to the user. In other case it will behave as before.
(0026736)
sureshbabu   
2010-04-28 07:52   
(edited on: 2010-04-28 08:02)
There is no conversion rate defined from (EUR-€) to (USD-$) for date '07-08-2006', Client 'BigBazaar' and Organization 'Main'. ORA-06512: at "TAD_240_FULL_QA.C_CURRENCY_RATE", line 112 ORA-06512: at "TAD_240_FULL_QA.C_CURRENCY_CONVERT", line 45 ORA-06512: at line 1

Right now in oracle context (2.40) i am getting the above error message if i run the report with out entering from and to date..


If i run the report in postgres context i am getting the expected error message.
      
There is no conversion rate defined from (EUR-€) to (USD-$) for date '31-03-2006', Client 'BigBazaar' and Organization 'Main'

(0027298)
hudsonbot   
2010-05-14 15:28   
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/19f1bedbb5ca [^]
Merge Changeset: http://code.openbravo.com/erp/devel/main/rev/36f76c8d7193 [^]
Tests: http://builds.openbravo.com/view/devel-int/ [^]
OBX: http://builds.openbravo.com/erp/core/obx/OpenbravoERP-2.50CI.17198.obx [^]
(0027345)
sureshbabu   
2010-05-17 07:54   
Tested
(0027991)
hgbot   
2010-06-04 14:46   
Repository: erp/devel/pi
Changeset: 07551d9c00f2f5e31ca771c18d8678ab3fe06a73
Author: Adrián Romero <adrianromero <at> openbravo.com>
Date: Mon Apr 26 15:10:45 2010 +0200
URL: http://code.openbravo.com/erp/devel/pi/rev/07551d9c00f2f5e31ca771c18d8678ab3fe06a73 [^]

Fixes issue 0012856: Error in 'Purchase Order Report

---
M src/org/openbravo/erpCommon/ad_reports/ReportPurchaseOrder.jrxml
---
(0028045)
arunkumar   
2010-06-07 11:40   
Tested working fine
(0028113)
hudsonbot   
2010-06-07 21:21   
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/07551d9c00f2 [^]
Merge Changeset: http://code.openbravo.com/erp/devel/main/rev/8b43a1f2fff4 [^]
Tests: http://builds.openbravo.com/view/int/ [^]
OBX: http://builds.openbravo.com/erp/core/obx/OpenbravoERP-2.50CI.17563.obx [^]
(0028155)
hudsonbot   
2010-06-07 23:43   
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/07551d9c00f2 [^]
Merge Changeset: http://code.openbravo.com/erp/devel/main/rev/8b43a1f2fff4 [^]
Tests: http://builds.openbravo.com/view/int/ [^]
OBX: http://builds.openbravo.com/erp/core/obx/OpenbravoERP-2.50CI.17563.obx [^]