3

I suddenly noticed that Oracle JDBC driver that I was using With Oracle 11g R2 was thinking that daylight savings time in US started after 2:59:59 am on March 13th this year. Actually, it started after 1:59:59 am. I did some additional testing and noticed that the buggy behavior of that driver did not depend on whether it talks to Oracle 11g R2 or Oracle 10g. Also, all available previous versions of that driver handle daylight savings time change correctly.

Is this a known bug? Is there a fix available for it?

Olaf
  • 6,249
  • 1
  • 19
  • 37

2 Answers2

4

Our DBA did research and found that this is a known bug and that a patch is available for it. Thanks everyone who cared to look into this and rake your brain for answers!

EDIT 9/25/2013: At the time of writing (over 2 years ago) a patch for the Oracle JDBC driver 11.2.0.2.0 was available to the paying Oracle customers. I have not tested personally, but I believe that the issue is resolved in the current version of the Oracle JDBC driver 11.2.0.4 which is available from Oracle for a free download.

Kara
  • 6,115
  • 16
  • 50
  • 57
Olaf
  • 6,249
  • 1
  • 19
  • 37
  • If you solve your own issue, please consider adding the solution (and patch number) rather than just stating the issue is solved - this way others can benefit from what you have discovered. – Dave Smylie Sep 22 '13 at 23:57
  • @Dave Smylie: I'm sory my answer was not clear enough. At the time of writing (over 2 years ago) a patch for the Oracle JDBC driver 11.2.0.2.0 was available to the paying Orcale customers. I have not tested personally, but I believe that the issue is resolved in the current version of the Oracle JDBC driver 11.2.0.4 which is available from Oracle for a free download. Take it easy! – Olaf Sep 23 '13 at 14:15
  • Cool. Thanks for the update/info. Very frustrating otherwise. I'd remove my downvote, but I can't now unless your answer is edited. – Dave Smylie Sep 24 '13 at 22:17
  • @DaveSmylie: I've added clarification to the answer itself. Thanks! – Olaf Sep 25 '13 at 13:21
0

Yes I agree that it is the driver. If your column is of type TIMESTAMP then Oracle will allow these invalid dates to get inserted into the DB then certain queries will throw

Error querying database. Cause: java.sql.SQLException: ORA-01878: specified field not found in datetime or interval

The error may involve defaultParameterMap

The error occurred while setting parameters

Cause: java.sql.SQLException: ORA-01878: specified field not found in datetime or interval

until the "bad" records are updated in the DB. This thread on stack overflow which was updated yesterday has the full detail. See the answer from Chris Williams

Oracle date compare broken because of DST

Community
  • 1
  • 1
Casey Johnson
  • 311
  • 1
  • 3
  • 13