I love Oracle! +

I execute this SQL with an Oracle 10g database with the latest JDBC driver (Oracle Thin 10.2.0.4).

Can you guess the difference between

select * from dual d where  d.dummy <= ‘X’ /* {} */

and

select * from dual d where  d.dummy <= ‘X’

?

Just a comment? -

Well, the surprise is, that the driver throws

java.lang.NullPointerException  at oracle.jdbc.driver.T4C8Oall.getNumRows(T4C8Oall.java:876)

in the first case that contains the comment and executes the statement correctly in the second case.

Thanks, Oracle!

One Response to “I love Oracle!”

  1. I have a similar problem with ora-thin 10.2.0.4, when calling a procedure that doesn’t return anything (i.e. no OUT parameters): surprise surprise – java.lang.NullPointerExceptionat at oracle.jdbc.driver.T4C8Oall.getNumRows(T4C8Oall.java:876).
    Tried googling and found that downgrading the driver should help – a community workaround, with Oracle being quiet all the way.

Leave a Reply

XHTML: You can use these tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>