We are connecting to database in standard fashion, using either JDBC driver, or JDBC:ODBC bridge. Here is the problem: if we try to connect to a running database but cannot connect(e.g. due to incorrect password), exception is thrown and we trap the error. This is good. However, if the database is stopped and we attempt connection, the connection is not made ('natch), but it does not throw any type of exception. The code in the calling servlet continues to merrily execute as if nothing is amiss. Is this normal? I am using code found in various books for my connection operation. Example of one of our methods for connecting:
public void makeOdbcConn() throws ClassNotFoundException, SQLException { Class.forName("sun.jdbc.odbc.JdbcOdbcDriver").newInstance(); conn = DriverManager.getConnection("jdbc:odbc:" + dsn, name, passwd); } this method would then be called inside a try block, with catch(Exception e). It does not go into the catch when database is not running. Does anyone else have this problem, or thoughts on this? We are using Sybase database, and JRun 3.1 for servlet container from which we make these database calls. Thanks in advance for advice. ___________________________________________________________________________ To unsubscribe, send email to [EMAIL PROTECTED] and include in the body of the message "signoff SERVLET-INTEREST". Archives: http://archives.java.sun.com/archives/servlet-interest.html Resources: http://java.sun.com/products/servlet/external-resources.html LISTSERV Help: http://www.lsoft.com/manuals/user/user.html