db-derby-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dirk Flachbart <flach...@gmail.com>
Subject Re: cancel a running query?
Date Fri, 10 Oct 2008 12:26:02 GMT
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
  <meta content="text/html;charset=ISO-8859-1" http-equiv="Content-Type">
<body bgcolor="#ffffff" text="#000000">
Doesn't Derby support Statement.setQueryTimeout() ?<br>
<a class="moz-txt-link-abbreviated" href="mailto:derby@segel.com">derby@segel.com</a>
<blockquote cite="mid:20081010115720.85A6A5FCF8@dbrack01.segel.com"
  <pre wrap="">A rollback doesn't "cancel" a query. Meaning that you can't stop the
until it completes.

The rollback will reverse the results of a transaction after the SQL
statement completes. A query is unaffected because its not a SQL statement
that changes the database. (query == SELECT, other statements UPDATE,DELETE,
INSERT, etc ... do change the data.)

So if you start  a query, there isn't a way to have some sort of query
timeout or call to prematurely end the query. (Perhaps you need to consider
threading your app...)



  <blockquote type="cite">
    <pre wrap="">-----Original Message-----
From: <a class="moz-txt-link-abbreviated" href="mailto:Dag.Wanvik@Sun.COM">Dag.Wanvik@Sun.COM</a>
[<a class="moz-txt-link-freetext" href="mailto:Dag.Wanvik@Sun.COM">mailto:Dag.Wanvik@Sun.COM</a>]
Sent: Thursday, October 09, 2008 9:09 PM
To: Derby Discussion
Subject: Re: cancel a running query?

Rick Hillegas <a class="moz-txt-link-rfc2396E" href="mailto:Richard.Hillegas@Sun.COM">&lt;Richard.Hillegas@Sun.COM&gt;</a>

    <blockquote type="cite">
      <pre wrap=""> conn.rollback();
    <pre wrap="">Doesn't the rollback block on synchronizion on the connection?

  <pre wrap=""><!---->


View raw message