OPENJPA-379. Creating the statement with the resultSetType, resultSetConcurrency specified consistent with the Kodos internal pool.

git-svn-id: https://svn.apache.org/repos/asf/openjpa/trunk@577991 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Srinivasa Segu 2007-09-21 05:54:55 +00:00
parent 5d4d50df96
commit 91917c406c
1 changed files with 3 additions and 1 deletions

View File

@ -23,6 +23,7 @@ import java.sql.CallableStatement;
import java.sql.Connection;
import java.sql.DatabaseMetaData;
import java.sql.PreparedStatement;
import java.sql.ResultSet;
import java.sql.SQLException;
import java.sql.SQLWarning;
import java.sql.Savepoint;
@ -162,7 +163,8 @@ public class DelegatingConnection implements Connection, Closeable {
if (_del != null)
stmnt = _del.prepareStatement(str, false);
else
stmnt = _conn.prepareStatement(str);
stmnt = _conn.prepareStatement(str, ResultSet.TYPE_FORWARD_ONLY,
ResultSet.CONCUR_READ_ONLY);
if (wrap)
stmnt = new DelegatingPreparedStatement(stmnt, this);
return stmnt;