Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-4986961

Statement.setQueryTimeout()

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: P3 P3
    • 6
    • 8.0pe
    • core-libs
    • rc
    • sparc
    • solaris_8
    • Verified

      1. When the query timeout expires before the statement finishes executing,
      should a driver send a cancel to the database()?
      2. With executeQuery() and executeUpdate(), it seems fairly reasonable to
      send a cancel, because these two methods return exactly one result, a
      ResultSet or an updatecount. However, with execute(), it may be that you're
      submitting a batch of three queries. Perhaps the first one executes and
      returns a resultset, but then the second times out... Your Results
      processing loop could catch the timeout exception and then call
      getMoreResults() because the third is ok and will return results...

      So, a more generic version of the question is -- when the query timeout
      expires, is the statement officially done? That is, should any further use
      of it be denied because the timeout expired? Again, the tricky point is what
      to expect when using Statement.execute, and you hit a timeout.
      ###@###.### 2004-02-02

            lancea Lance Andersen
            lancea Lance Andersen
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: