if you catch SQLExceptions, any other type of exception will go unhandled. You really only need to handle the SQL excpetion if it has info you need that the exception doesn't (I havent had this problem since the Excpetion has always had all the info i needed to find the problem)
But if you want to get really fancy, you can catch BOTH types of exceptions. You do this by declaring two catch blocks, one with each exception type. When an error gets raised, the catch block with the appropriate exception will get fired, for example:
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.