Re: ??? (Statement)setQueryTimeout(int) ???
Date: 2000/06/30
Message-ID: <395CFDB6.B97E6D61_at_weblogic.com>#1/1
King wrote:
>
> Hi,
>
> Does anyone use JDBC 2.0 Statement api setQueryTimeout(int)? Does it work?
> I tried to set the time limits and expected the program throw SQLException.
Hi. I believe that Oracle's wire-level client-DBMS protocol is currently incapable of interupting a query, once sent, so there is no way for their driver to implement this JDBC function. You should certainly confirm this with Oracle, but this is my understanding.
Joe Weinstein at BEA
>
> I inspect the 'statement' object and it's query_timeout was reset (to 1
> second)correctly, and I was pretty sure that the query would take more than
> one second ( it read 1000 objects from the database, and I even put
> Thread.sleep(1000) before the statement.close() call). I wanted to see/catch
> the arisen SQLException, but my program always passed without exception
> occurred.
>
> I used VA3.0 for jdk1.2 and Oracle8i Enterprise Edition Release 8.1.6 server
> with 8.1.5 driver.
>
> TIA
> King
-- PS: Folks: BEA WebLogic is in S.F., and now has some entry-level positions for people who want to work with Java and E-Commerce infrastructure products. Send resumes to joe_at_beasys.com -------------------------------------------------------------------------------- The Weblogic Application Server from BEA JavaWorld Editor's Choice Award: Best Web Application Server Java Developer's Journal Editor's Choice Award: Best Web Application Server Crossroads A-List Award: Rapid Application Development Tools for Java Intelligent Enterprise RealWare: Best Application Using a Component Architecture http://weblogic.beasys.com/press/awards/index.htmReceived on Fri Jun 30 2000 - 00:00:00 CEST