By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
454,278 Members | 1,530 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 454,278 IT Pros & Developers. It's quick & easy.

jdbc statement.setQueryTimeout

P: n/a
I use db2jcc.jar from 8.1 client.

Is there a way to set up timeout before executing statement?

statement.setQueryTimeout does not timeout on execution of
statement.execute.

This works in SQL Server and Sybase Driver. On Oracle it is a different
implementation using property which also works but I could not find how to
make this one work.

Any recommendation will be welcomed.

Thanks,
MarcM

Oct 18 '06 #1
Share this Question
Share on Google+
1 Reply


P: n/a
Marc Melancon wrote:
I use db2jcc.jar from 8.1 client.

Is there a way to set up timeout before executing statement?
Hm... It is (or at least was) implemented in the jdbc.net and the
jdbc.app of v7.1.

The timeout is given in seconds (not milliseconds), check if an
exception is thrown at setQueryTimeout(..) and verify the value with
getQueryTimeout().

Bernd

--
What do you get when you cross a mail pigeon with a parrot ? Voice mail
Oct 19 '06 #2

This discussion thread is closed

Replies have been disabled for this discussion.