title: safety of setObject and null
body: <p><a href="http://docs.oracle.com/javase/6/docs/api/java/sql/PreparedStatement.html#setObject%28int,%20java.lang.Object%29" rel="nofollow">PreparedStatement.setObject</a>'s  Javadoc says it's not safe to just pass null value, and recommends using setNull instead, which requires to pass the column DB type along.</p>
  
  <p>Since it's not trivial to tell type of a null value in Java, I wonder if there's any resource listing the safety of calling setObject with null value for popular databases?</p>