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

View Issue DetailsJump to Notes ] Issue History ] Print ]
ID
0005849
TypeCategorySeverityReproducibilityDate SubmittedLast Update
backport[Openbravo ERP] 09. Financial managementmajoralways2008-11-06 12:152008-12-09 11:14
ReportergalderromoView Statuspublic 
Assigned Todalsasua 
PriorityimmediateResolutionfixedFixed in Version2.35MP10
StatusclosedFix in branch2.3xFixed in SCM revision10578
ProjectionnoneETAnoneTarget Version
OSLinux 32 bitDatabaseOracleJava version1.5.0_15
OS VersionGentoo 2.6.24Database versionXEAnt version1.7
Product Version2.35MP5SCM revision 
Review Assigned To
Web browser
ModulesCore
Regression level
Regression date
Regression introduced in release
Regression introduced by commit
Triggers an Emergency PackNo
Summary

0005849: General Ledger: Accumulated amounts when using more than a range

DescriptionWhen having more than 500 records, the report shows more than a view.
The break between ranges can happend during the same accounting date. On this cases, the new range's amounts are not proparly calculated.
Steps To ReproduceSupposing you have this records on facct_acct:
Date: 11-08-08 fact_acct_id:1000 amount:1000
Date: 11-08-08 fact_acct_id:1001 amount:800
---------------- Range break ----------------
Date: 11:08-08 fact_acct_id:1002 amount:350
Date: 12-08-08 fact_acct_id:1003 amount:100

When the new range is loaded, you previous amount will be 2150 instead of 1800.

Proposed SolutionChange selectPrevious method on ReportGeneralLedger_data.xsql with:
  <SqlMethod name="selectPrevious" type="preparedStatement" return="multiple">
      <SqlMethodComment></SqlMethodComment>
      <Sql><![CDATA[
      SELECT COALESCE(SUM(AMTACCTDR),0) AS TOTALDR, COALESCE(SUM(AMTACCTCR),0) AS TOTALCR,
      COALESCE(SUM(AMTACCTDR-AMTACCTCR),0) AS TOTAL
      FROM FACT_ACCT
      WHERE 1=1
      AND FACT_ACCT.ACCOUNT_ID = ?
      AND (DATEACCT < ? OR (DATEACCT= ? AND FACT_ACCT_ID < ? ))
      AND FACT_ACCT.AD_ORG_ID IN ('1')
      AND 2=2
      ]]></Sql>
      <Parameter name="bpartner" optional="true" after="1=1"><![CDATA[ AND FACT_ACCT.C_BPARTNER_ID = ? ]]></Parameter>
      <Parameter name="project" optional="true" after="1=1"><![CDATA[ AND FACT_ACCT.C_PROJECT_ID = ? ]]></Parameter>
      <Parameter name="acctschema" optional="true" after="1=1"><![CDATA[ and fact_acct.C_ACCTSCHEMA_ID = ? ]]></Parameter>
      <Parameter name="account"/>
      <Parameter name="date"/>
      <Parameter name="date"/>
      <Parameter name="factacct"/>
      <Parameter name="orgs" type="replace" optional="true" after="AND FACT_ACCT.AD_ORG_ID IN (" text="'1'"/>
      <Parameter name="productId" optional="true" type="argument" after="2=2"><![CDATA[ AND FACT_ACCT.M_PRODUCT_ID IN ]]></Parameter>
      <Parameter name="user1" optional="true" after="2=2"><![CDATA[ AND fact_acct.USER1_ID = ? ]]></Parameter>
      <Parameter name="user2" optional="true" after="2=2"><![CDATA[ AND fact_acct.USER2_ID = ? ]]></Parameter>
   </SqlMethod>
TagsNo tags attached.
Attached Files

- Relationships Relation Graph ] Dependency Graph ]
blocks defect 0005096 closeddalsasua General Ledger: Accumulated amounts when using more than a range 

-  Notes
(0010048)
svnbot (reporter)
2008-11-06 17:16

Repository: openbravo
Revision: 9758
Author: davidalsasua
Date: 2008-11-06 17:16:08 +0100 (Thu, 06 Nov 2008)

Fixes Bug 0005849 General Ledger: Accumulated amounts when using more than a range

---
U branches/r2.3x/src/org/openbravo/erpCommon/ad_reports/ReportGeneralLedger.html
U branches/r2.3x/src/org/openbravo/erpCommon/ad_reports/ReportGeneralLedger.java
U branches/r2.3x/src/org/openbravo/erpCommon/ad_reports/ReportGeneralLedger.xml
---

https://dev.openbravo.com/websvn/openbravo/?rev=9758&sc=1 [^]
(0010427)
networkb (developer)
2008-11-20 10:12

This bug is not solved
(0010524)
svnbot (reporter)
2008-11-21 18:52

Repository: openbravo
Revision: 10418
Author: davidalsasua
Date: 2008-11-21 18:52:44 +0100 (Fri, 21 Nov 2008)

Fixes Bug 0005849: General Ledger: Accumulated amounts when using more than a range.

Also number format and classes changed so accounting reports are more readable.

---
U branches/r2.3x/config/Format.xml
U branches/r2.3x/src/org/openbravo/erpCommon/ad_reports/ReportGeneralLedger.html
U branches/r2.3x/src/org/openbravo/erpCommon/ad_reports/ReportGeneralLedger.java
U branches/r2.3x/src/org/openbravo/erpCommon/ad_reports/ReportGeneralLedger.xml
U branches/r2.3x/src/org/openbravo/erpCommon/ad_reports/ReportGeneralLedger_data.xsql
U branches/r2.3x/src/org/openbravo/erpCommon/ad_reports/Totals.srpt
U branches/r2.3x/web/skins/Default/Main/Client/DataGrid/DataGrid.css
---

https://dev.openbravo.com/websvn/openbravo/?rev=10418&sc=1 [^]
(0010577)
svnbot (reporter)
2008-11-24 17:20

Repository: openbravo
Revision: 10479
Author: davidalsasua
Date: 2008-11-24 17:20:40 +0100 (Mon, 24 Nov 2008)

Fixes Bug 0005849: General Ledger: Accumulated amounts when using more than a range

---
U branches/r2.3x/src/org/openbravo/erpCommon/ad_reports/ReportGeneralLedger_data.xsql
---

https://dev.openbravo.com/websvn/openbravo/?rev=10479&sc=1 [^]
(0010614)
svnbot (reporter)
2008-11-25 11:28

Repository: openbravo
Revision: 10523
Author: vmromanos
Date: 2008-11-25 11:27:45 +0100 (Tue, 25 Nov 2008)

Fixed bug 0005849: General Ledger: Accumulated amounts when using more than a range

---
U branches/r2.3x/src/org/openbravo/erpCommon/ad_reports/ReportGeneralLedger_data.xsql
---

https://dev.openbravo.com/websvn/openbravo/?rev=10523&sc=1 [^]
(0010662)
svnbot (reporter)
2008-11-25 18:33

Repository: openbravo
Revision: 10578
Author: davidalsasua
Date: 2008-11-25 18:33:21 +0100 (Tue, 25 Nov 2008)

Fixes Bug 0005849: General Ledger: Accumulated amounts when using more than a range

---
U branches/r2.3x/src/org/openbravo/erpCommon/ad_reports/ReportGeneralLedger_data.xsql
---

https://dev.openbravo.com/websvn/openbravo/?rev=10578&sc=1 [^]

- Issue History
Date Modified Username Field Change
2008-11-06 12:15 psarobe New Issue
2008-11-06 12:15 psarobe Assigned To => dalsasua
2008-11-06 12:15 psarobe Status new => scheduled
2008-11-06 12:16 psarobe Priority high => immediate
2008-11-06 12:16 psarobe Steps to Reproduce Updated
2008-11-06 17:16 svnbot Checkin
2008-11-06 17:16 svnbot Note Added: 0010048
2008-11-06 17:16 svnbot Status scheduled => resolved
2008-11-06 17:16 svnbot Resolution open => fixed
2008-11-06 17:16 svnbot svn_revision 8304 => 9758
2008-11-20 10:12 networkb Status resolved => new
2008-11-20 10:12 networkb Resolution fixed => open
2008-11-20 10:12 networkb Note Added: 0010427
2008-11-21 18:52 svnbot Checkin
2008-11-21 18:52 svnbot Note Added: 0010524
2008-11-21 18:52 svnbot Status new => resolved
2008-11-21 18:52 svnbot Resolution open => fixed
2008-11-21 18:52 svnbot svn_revision 9758 => 10418
2008-11-24 17:20 svnbot Checkin
2008-11-24 17:20 svnbot Note Added: 0010577
2008-11-24 17:20 svnbot svn_revision 10418 => 10479
2008-11-25 11:28 svnbot Checkin
2008-11-25 11:28 svnbot Note Added: 0010614
2008-11-25 11:28 svnbot svn_revision 10479 => 10523
2008-11-25 18:33 svnbot Checkin
2008-11-25 18:33 svnbot Note Added: 0010662
2008-11-25 18:33 svnbot svn_revision 10523 => 10578
2008-12-09 11:14 psarobe Regression testing => No
2008-12-09 11:14 psarobe Status resolved => closed


Copyright © 2000 - 2009 MantisBT Group
Powered by Mantis Bugtracker