title: Calling a Stored Procedure from Java - Exception not thrown on ORA error
body: <p>I'm calling an Oracle Stored Procedure from Java, and have no problem sending input parameter values and getting the output parameter values back to Java once I execute the <code>CallableStatement</code>.</p>
  
  <p>However, when i send some bad data into the Stored Procedure (to force an error) and execute the <code>CallableStatement</code>'s <code>execute</code> method, I'd expect a <code>SQLException</code> to be thrown in my method. This doesn't happen, and the code continues as normal.</p>
  
  <p>When I run the Stored Procedure through SQL Developer, i can clearly see an oracle error message (code <code>ORA-06502</code>) displayed in the Log window. So it's a mystery to me why my Java code isn't catching any error message.</p>
  
  <p>Does anyone have an idea what the source of this behaviour is? Is the Stored Procedure not throwing the error correctly; is the Java <code>try/catch</code> not recognizing the exception thrown? Unfortunately i have no access to the Stored Proc code to check how they're handling errors.</p>
  
  <p>Any pointers are appreciated.</p>