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(); }