Wrox Programmer Forums
|
Java Databases Discussion specific to working with Java Databases. For other Java topics, please see related Java forums. For database discussions not specific to Java, please see the Database category.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Java Databases section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old September 23rd, 2003, 09:17 AM
Registered User
 
Join Date: Jul 2003
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default Testing connection

Hello,

how can I test connection to DB to chech if application is still connected?

Thank you, Andrej
 
Old September 23rd, 2003, 09:30 AM
Friend of Wrox
 
Join Date: Jun 2003
Posts: 175
Thanks: 0
Thanked 0 Times in 0 Posts
Default

use Connection.isClosed. See JavaDoc for more information.

cheers

Martyn
 
Old September 23rd, 2003, 09:33 AM
Friend of Wrox
 
Join Date: Jun 2003
Posts: 175
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Opps! Sorry, I forgot the brackets, it is a method call and it should have read Connection.isClosed()


cheers

Martyn





Similar Threads
Thread Thread Starter Forum Replies Last Post
testing locally but using remote connection string JezHarvey BOOK: ASP.NET 2.0 Website Programming Problem Design Solution ISBN: 978-0-7645-8464-0 4 August 12th, 2008 07:28 AM
Testing for ChannelMode interrupt Javascript How-To 0 June 30th, 2006 08:21 AM
need self testing questions netcat Perl 1 April 22nd, 2006 06:21 AM
Testing for integer MattLeek Excel VBA 8 March 7th, 2004 09:15 AM
testing mark C# 0 June 4th, 2003 08:37 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.