From b45109cec3f0541b97b8d436a3026bf5242f75cb Mon Sep 17 00:00:00 2001 From: Catalina Wei Date: Sat, 7 Mar 2009 17:49:31 +0000 Subject: [PATCH] OPENJPA-965 Open up FinderCacheImpl for non-JDBC or JDBC-like implementation of preparing statement/query execution An approache not exposing FinderCacheImpl to jdbc kernel git-svn-id: https://svn.apache.org/repos/asf/openjpa/trunk@751301 13f79535-47bb-0310-9956-ffa450edef68 --- .../java/org/apache/openjpa/jdbc/kernel/FinderQueryImpl.java | 3 ++- .../src/main/java/org/apache/openjpa/jdbc/sql/SelectImpl.java | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/kernel/FinderQueryImpl.java b/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/kernel/FinderQueryImpl.java index ccc425c67..c5ccef4fa 100644 --- a/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/kernel/FinderQueryImpl.java +++ b/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/kernel/FinderQueryImpl.java @@ -150,7 +150,8 @@ public class FinderQueryImpl } } - rs = _select.executeQuery(conn, stmnt, this, jstore, params); + rs = _select.executeQuery(conn, stmnt, getQueryString(), jstore, + params); return _select.getEagerResult(conn, stmnt, rs, jstore, (JDBCFetchConfiguration)fetch, forUpdate, _buffer); } catch (SQLException se) { diff --git a/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/sql/SelectImpl.java b/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/sql/SelectImpl.java index 20813c985..0b0c0c705 100644 --- a/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/sql/SelectImpl.java +++ b/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/sql/SelectImpl.java @@ -484,7 +484,7 @@ public class SelectImpl * implementation of executing query. */ public ResultSet executeQuery(Connection conn, PreparedStatement stmnt, - FinderQueryImpl finder, JDBCStore store, Object[] params) + String sql, JDBCStore store, Object[] params) throws SQLException { return stmnt.executeQuery(); }