steve wrote:
I am assuming this is yet another Oracle driver bug. But feel free to create a JIRA case and attach a small runnable test case reproducing this problem if you think otherwise.
I just ran into this problem with a production application of mine. Caused a crash. Very annoying. Steve is correct in that this is definitely an Oracle JDBC driver bug. I was able to write a simple test case using plain old JDBC to reproduce the problem. Further testing revealed that the latest Oracle JDBC driver (10.2.0.1.0) resolves this issue completely. In fact, this issue is mentioned as one of the bugs fixed in the release.
From the README:
BUG-4365273
NullPointerException when calling executeBatch after previous call
on same statement resulted in an error. This problem occurs
occasionally when using statement caching and Fast Connection
Failover. A workaround is to call clearBatch in a catch block
wrapped around the call to executeBatch.
--
So for those of you experiencing this problem upgrading to the 10.2.0.1.0 Oracle JDBC driver will fix the problem.
Corey