Error "java.text.ParseException: Unparseable date" due to Missing Trailing ".0" in Date String Retrieved from Database Using ResultSet.getString() on a Date/Timestamp Column

(Doc ID 1144676.1)

Last updated on JULY 14, 2011

Applies to:

JDBC - Version: and later   [Release: 11.2 and later ]
Information in this document applies to any platform.


You have noticed that when you retrieve a DATE field from the database using the method ResultSet.getString(), the date string is missing the trailing ".0"

The value returned when the date string is fetched with Oracle JDBC is of the form:
2010-04-14 00:00:00’ 
whereas the value returned when the same is fetched with Oracle JDBC or lower versions is of the form:
2010-04-14 00:00:00.0

This causes following exception when your Java code tries to parse the value to Date format:
java.text.ParseException: Unparseable date: "2010-05-31 00:00:00"
at java.text.DateFormat.parse(
at JdbcVersion.selectDate(
at JdbcVersion.main(


You have recently upgraded your Oracle JDBC driver to


Sign In with your My Oracle Support account

Don't have a My Oracle Support account? Click to get started

My Oracle Support provides customers with access to over a
Million Knowledge Articles and hundreds of Community platforms