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 handling RuntimeException Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Databases » JDBC and Relational Databases
Bookmark "handling RuntimeException" Watch "handling RuntimeException" New topic

handling RuntimeException

Jignesh Patel
Ranch Hand

Joined: Nov 03, 2001
Posts: 626

My application throws net.sf.hibernate.JDBCException e, which in turn throws java.sql.BatchUpdateException.

I want to catch above exception, but since it is RuntimeException, I couldn't.

Can anybody assist me to catch RuntimeException.
Kunaal A Trehan
Ranch Hand

Joined: Feb 04, 2004
Posts: 63
If u catch exception superclass u wud be able to
catch runtime exception also

I agree. Here's the link:
subject: handling RuntimeException
It's not a secret anymore!