Skip to Main Content

Database Software

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Timestamp/Date format error with Java 1.6

493599Mar 18 2008 — edited Jul 7 2009
I'm getting this error trying to getObjects from a ResultSet query for an Oracle Lite 10G table that has colums of the TIMESTAMP or DATE type. This works fine under java 1.5. Java 1.6 seems to have broken TIMESTAMP/DATE compatibility with Oracle Lite. Are there any plans to make 10G compatible with Java 1.6? We would like to port our application from Java 1.5 to 1.6, but this is an obstacle. I suppose one work-around would be to use TO_CHAR on all the DATE fields and convert them back to java Dates programatically, but that would be a hassle.

Update: I changed the column types of the table from TIMESTAMP to DATE. The same exception occurs when calling POLJDBCResultSet.getObject() on the DATE columns. Again, this works fine under Java 1.5, but not 1.6.

java.lang.IllegalArgumentException: Timestamp format must be yyyy-mm-dd hh:mm:ss[.fffffffff]
at java.sql.Timestamp.valueOf(Timestamp.java:194)
at oracle.lite.poljdbc.LiteEmbResultSet.jniGetDataTimestamp(Native Method)
at oracle.lite.poljdbc.LiteEmbResultSet.getVal(Unknown Source)
at oracle.lite.poljdbc.POLJDBCResultSet.getTimestamp(Unknown Source)
at oracle.lite.poljdbc.POLJDBCResultSet.getObject(Unknown Source)
at oracle.lite.poljdbc.POLJDBCResultSet.getObject(Unknown Source)
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Aug 4 2009
Added on Mar 18 2008
17 comments
14,673 views