You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@fineract.apache.org by vo...@apache.org on 2021/12/23 17:20:45 UTC

[fineract] branch develop updated: FINERACT-1089: Fixing 'Operation not allowed for a result set of type ResultSet.TYPE_FORWARD_ONLY'

This is an automated email from the ASF dual-hosted git repository.

vorburger pushed a commit to branch develop
in repository https://gitbox.apache.org/repos/asf/fineract.git


The following commit(s) were added to refs/heads/develop by this push:
     new 7b4fcb9  FINERACT-1089: Fixing 'Operation not allowed for a result set of type ResultSet.TYPE_FORWARD_ONLY'
7b4fcb9 is described below

commit 7b4fcb9549d27768eb3097a10e07dd2311e7fe3f
Author: Petri Tuomola <pe...@tuomola.org>
AuthorDate: Wed Nov 24 21:33:22 2021 +0800

    FINERACT-1089: Fixing 'Operation not allowed for a result set of type ResultSet.TYPE_FORWARD_ONLY'
---
 .../service/InterestRateChartReadPlatformServiceImpl.java            | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/fineract-provider/src/main/java/org/apache/fineract/portfolio/interestratechart/service/InterestRateChartReadPlatformServiceImpl.java b/fineract-provider/src/main/java/org/apache/fineract/portfolio/interestratechart/service/InterestRateChartReadPlatformServiceImpl.java
index 53101e4..e490cd7 100644
--- a/fineract-provider/src/main/java/org/apache/fineract/portfolio/interestratechart/service/InterestRateChartReadPlatformServiceImpl.java
+++ b/fineract-provider/src/main/java/org/apache/fineract/portfolio/interestratechart/service/InterestRateChartReadPlatformServiceImpl.java
@@ -99,7 +99,10 @@ public class InterestRateChartReadPlatformServiceImpl implements InterestRateCha
         sql.append("WHEN !isPrimaryGroupingByAmount then ircd.amount_range_to ");
         sql.append("END");
 
-        return this.jdbcTemplate.query(sql.toString(), this.chartExtractor, new Object[] { productId });
+        return this.jdbcTemplate.query(
+                con -> con.prepareStatement(sql.toString(), ResultSet.TYPE_SCROLL_INSENSITIVE, ResultSet.CONCUR_UPDATABLE),
+                ps -> ps.setLong(1, productId), this.chartExtractor);
+
     }
 
     @Override