title: Catching SQL errors in JAVA?
body: <p>I'm getting <code>SQL</code> result sets in <code>Java</code> from my <code>Oracle DB</code> and I want to know if and how I can record/catch SQL errors in <code>Java</code>. So when I try to execute some <code>SQL</code>:</p>
  
  <pre><code>ResultSet resultSet = connection.executeQuery(query);
  </code></pre>
  
  <p>I get an error like <code>ORA-00942: table or view does not exist</code>. How can I record that? </p>