File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes JDBC and Relational Databases and the fly likes SQL-server Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Head First Android this week in the Android forum!
JavaRanch » Java Forums » Databases » JDBC and Relational Databases
Bookmark "SQL-server" Watch "SQL-server" New topic


Henk Rog
Ranch Hand

Joined: Dec 04, 2003
Posts: 36
Is there a method to check if an SQL-server is running?
Christian Wolf

Joined: Dec 15, 2003
Posts: 28
Is there a method to check if an SQL-server is running?
*g* Sure. The same method as with every server. Try to connect to it. Either it fails (timeout) or you get a response from the server.
Christian Wolf
Jessica Sant

Joined: Oct 17, 2001
Posts: 4313

moving this to the JDBC forum
(even though I'm pretty sure Christian gave you the best answer -- just be sure to check for an exception to come back!)
It is sorta covered in the JavaRanch Style Guide.
subject: SQL-server
It's not a secret anymore!