Last updated on MARCH 08, 2017
Applies to:JDBC - Version: 10.1.0.4 to 11.1
This problem can occur on any platform.
Find that running a query "select sys_xmlgen(1) from dual" from a java program using a JDBC driver with the connection cache enabled, results in the database process consuming more and more memory for every iteration until it crashed .
Your java code looks like:
OracleDataSource ods = new OracleDataSource();
ods.setURL("jdbc:oracle:thin:@" + url );
// Retrieve connection.
Connection conn = ods.getConnection();
// Iterate to show database memory increasing.
int i = 0;
boolean b = true;
conn = ods.getConnection();
String sql = "select sys_xmlgen(1) from dual ";
OracleCallableStatement st = (OracleCallableStatement)conn.prepareCall(sql);
ResultSet results = st.executeQuery();
int rowCount = 0;
Sign In with your My Oracle Support account
Don't have a My Oracle Support account? Click to get started
Million Knowledge Articles and hundreds of Community platforms