fixed bug 26030: OOM Error in Oracle due to prepared statements
authorAsier Lostalé <asier.lostale@openbravo.com>
Tue, 18 Mar 2014 15:49:50 +0100
changeset 22723 3f37631fbc2c
parent 22722 2c8c88e823d2
child 22724 30ff720d9b52
fixed bug 26030: OOM Error in Oracle due to prepared statements
Reduced fetch size not to use so much memory
src/org/openbravo/costing/CostingBackground.java
--- a/src/org/openbravo/costing/CostingBackground.java	Tue Mar 18 13:13:14 2014 +0000
+++ b/src/org/openbravo/costing/CostingBackground.java	Tue Mar 18 15:49:50 2014 +0100
@@ -197,7 +197,7 @@
         MaterialTransaction.class, where.toString());
     trxQry.setFilterOnReadableOrganization(false);
     trxQry.setNamedParameter("orgs", orgsWithRule);
-    trxQry.setFetchSize(1000);
+    trxQry.setFetchSize(10);
 
     return trxQry.scroll(ScrollMode.FORWARD_ONLY);
   }