Issue Details (XML | Word | Printable)

Key: JDBC-571
Type: Bug Bug
Status: Closed Closed
Resolution: Fixed
Priority: Major Major
Assignee: Mark Rotteveel
Reporter: Mark Rotteveel
Votes: 0
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
Jaybird JCA/JDBC Driver

Error "Current statement state (CURSOR_OPEN) does not allow call to prepare" when creating result set fails

Created: 28/Dec/18 07:55 PM   Updated: 25/May/19 10:03 AM
Component/s: JDBC driver
Affects Version/s: Jaybird 3.0.5, Jaybird 4
Fix Version/s: Jaybird 3.0.6, Jaybird 4

Issue Links:
Relate
 


 Description  « Hide
Running TestScalarTimeDateFunctions against Firebird 4 results in a reproducible case of "Current statement state (CURSOR_OPEN) does not allow call to prepare". The cause is similar to JDBC-531, except in this case initialization of the fields in the result set constructor fails due to an unsupported datatype (eg TIMESTAMP WITH TIME ZONE). The failure to create the result set causes the result set to never be closed, and therefor the cursor state is never reset (and the serverside cursor never closed).

We need to carefully check if other types of exception can also lead to not properly closing result sets / cursors. We may also want to consider implementing a stopgap measure that prevents this problem from causing problems outside the driver (eg by forcibly resetting the statement if the state is CURSOR_OPEN). Maybe FBStatement.notifyStatementStarted should call something on FbStatement that forces a close if necessary.

 All   Comments   Change History   Subversion Commits      Sort Order: Ascending order - Click to sort in descending order
Mark Rotteveel made changes - 29/Dec/18 01:21 PM
Field Original Value New Value
Fix Version/s Jaybird 3.0.6 [ 10883 ]
Fix Version/s Jaybird 4 [ 10441 ]
Mark Rotteveel made changes - 29/Dec/18 01:36 PM
Status Open [ 1 ] Resolved [ 5 ]
Resolution Fixed [ 1 ]
Mark Rotteveel made changes - 29/Dec/18 01:42 PM
Link This issue relate to JDBC-573 [ JDBC-573 ]
Mark Rotteveel made changes - 25/May/19 10:03 AM
Status Resolved [ 5 ] Closed [ 6 ]