java.jdbc

Allow setting the timeout on a prepared statement

Details

  • Type: Enhancement Enhancement
  • Status: Closed Closed
  • Priority: Major Major
  • Resolution: Completed
  • Affects Version/s: None
  • Fix Version/s: None
  • Component/s: None
  • Labels:
    None

Description

This could be done via a new :timeout option to prepare-statement, or a generic option somewhere that allows manipulating the prepared statement prior to making a query.

Activity

Hide
Sean Corfield added a comment -

Given that both query and execute! support passing a PreparedStatement in place of the SQL string, this is already possible. You can create a PreparedStatement with the prepare-statement function and then set a timeout or whatever you want, then pass it into query or execute!.

That said, adding support for it directly on prepare-statement seems like a reasonable enhancement since that's where all the other fancy PreparedStatement stuff is done.

Show
Sean Corfield added a comment - Given that both query and execute! support passing a PreparedStatement in place of the SQL string, this is already possible. You can create a PreparedStatement with the prepare-statement function and then set a timeout or whatever you want, then pass it into query or execute!. That said, adding support for it directly on prepare-statement seems like a reasonable enhancement since that's where all the other fancy PreparedStatement stuff is done.
Hide
Sean Corfield added a comment -

Added :timeout to prepare-statement. Will be in 0.3.6.

Show
Sean Corfield added a comment - Added :timeout to prepare-statement. Will be in 0.3.6.

People

Vote (0)
Watch (0)

Dates

  • Created:
    Updated:
    Resolved: