Subject Reusing a Statement instance
Author Andrew

Recently I have encountered an exception when tried to reuse the same
Statement instance.

The code looks like this:

Statement stmt = connection.CreateStatement();
ResultSet rs = stmt.executeQuery("select * from config");
if ( {
rs = stmt.executeQuery(sql); // <--- This line causes
"org.firebirdsql.jdbc.FBSQLException: This statement is already closed."

My application is for Java 1.4.2. The driver version is 2.1.6 for
jdk1.4. The application uses pooled pure-java connection.
I have googled for the similar problems and found this:

Please clarify the situation.

Best regards,