New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
FBPreparedStatement and FBCallableStatement not compliant for java.sql.Statement methods [JDBC288] #334
Comments
Modified by: @mrotteveeldescription: The current implementation of FBPreparedStatement and FBCallableStatement are not compliant with the JDBC specification as they allow use of methods defined on java.sql.Statement that are explicitly marked with "Note:This method cannot be called on a PreparedStatement or CallableStatement." in the Javadoc. These are mostly the methods that accept a string with a query. These methods should be modified to throw an SQLException. => The current implementation of FBPreparedStatement and FBCallableStatement are not compliant with the JDBC specification as they allow use of methods defined on java.sql.Statement that are explicitly marked with "Note:This method cannot be called on a PreparedStatement or CallableStatement." in the Javadoc. These are mostly the methods that accept a string with a query. These methods should be modified to throw an SQLException. |
Modified by: @mrotteveeldescription: The current implementation of FBPreparedStatement and FBCallableStatement are not compliant with the JDBC specification as they allow use of methods defined on java.sql.Statement that are explicitly marked with "Note:This method cannot be called on a PreparedStatement or CallableStatement." in the Javadoc. These are mostly the methods that accept a string with a query. These methods should be modified to throw an SQLException. => The current implementation of FBPreparedStatement and FBCallableStatement are not compliant with the JDBC specification as they allow use of methods defined on java.sql.Statement that are explicitly marked with "Note:This method cannot be called on a PreparedStatement or CallableStatement." in the Javadoc (this was added with JDBC 4.0). These are mostly the methods that accept a string with a query. These methods should be modified to throw an SQLException in FBPreparedStatement and/or FBCallableStatement. It would probably also be a good idea to review the current class hierarchy and see if it is actually sensible that FBPreparedStatement extends FBStatement and that FBCallableStatement extends FBPreparedStatement. |
Modified by: @mrotteveeldescription: The current implementation of FBPreparedStatement and FBCallableStatement are not compliant with the JDBC specification as they allow use of methods defined on java.sql.Statement that are explicitly marked with "Note:This method cannot be called on a PreparedStatement or CallableStatement." in the Javadoc (this was added with JDBC 4.0). These are mostly the methods that accept a string with a query. These methods should be modified to throw an SQLException in FBPreparedStatement and/or FBCallableStatement. It would probably also be a good idea to review the current class hierarchy and see if it is actually sensible that FBPreparedStatement extends FBStatement and that FBCallableStatement extends FBPreparedStatement. => The current implementation of FBPreparedStatement and FBCallableStatement are not compliant with the JDBC specification as they allow use of methods defined on java.sql.Statement that are explicitly marked with "Note:This method cannot be called on a PreparedStatement or CallableStatement." in the Javadoc (this was added with JDBC 4.0). These are mostly the methods that accept a string with a query. These methods should be modified to throw an SQLException in FBPreparedStatement and/or FBCallableStatement. It would probably also be a good idea to review the current class hierarchy and see if it is actually sensible that FBPreparedStatement extends FBStatement and that FBCallableStatement extends FBPreparedStatement. Example of problem: http://stackoverflow.com/q/13754898/466862 |
Commented by: @mrotteveel Scheduling for Jaybird 2.3, need to think if it also needs to be backported to 2.2.2; essentially this has always been broken. |
Modified by: @mrotteveelFix Version: Jaybird 2.3 [ 10440 ] |
Commented by: @mrotteveel Committed short-term fix and additional tests. I will review class-hierarchy at a later date. |
Commented by: @mrotteveel Decided to also backport the basic fix to 2.2.2 |
Modified by: @mrotteveelFix Version: Jaybird 2.2.2 [ 10480 ] |
Commented by: @mrotteveel Created subtask for review/refactor. Closing this ticket as fixed. |
Modified by: @mrotteveelstatus: Resolved [ 5 ] => Closed [ 6 ] |
Submitted by: @mrotteveel
Jira_subtask_outward JDBC289
The current implementation of FBPreparedStatement and FBCallableStatement are not compliant with the JDBC specification as they allow use of methods defined on java.sql.Statement that are explicitly marked with "Note:This method cannot be called on a PreparedStatement or CallableStatement." in the Javadoc (this was added with JDBC 4.0). These are mostly the methods that accept a string with a query.
These methods should be modified to throw an SQLException in FBPreparedStatement and/or FBCallableStatement. It would probably also be a good idea to review the current class hierarchy and see if it is actually sensible that FBPreparedStatement extends FBStatement and that FBCallableStatement extends FBPreparedStatement.
Example of problem: http://stackoverflow.com/q/13754898/466862
Commits: 2152962 07020e1
The text was updated successfully, but these errors were encountered: