-
Notifications
You must be signed in to change notification settings - Fork 367
Description
Shrinivaasan opened DATAJDBC-3 and commented
JdbcTemplate is not supporting all the DataBases. An exception is thrown, while accessing Timestamp value from SQLite Db using JdbcTemplate. Since the java.sql.Timestamp values are stored as String/long values in SQLite data base, using the getTimestap() method fails throwing the below exception.
org.springframework.jdbc.InvalidResultSetAccessExc eption: getTime failed on value ( {0} ) in column {1} no conversion available12901443977182; nested exception is java.sql.SQLException: getTime failed on value ( {0} ) in column {1} no conversion available12901443977182
at org.springframework.jdbc.support.rowset.ResultSetW rappingSqlRowSet.getTimestamp(ResultSetWrappingSql RowSet.java:518)
at TestSqliteUsingSpring.getData(TestSqliteUsingSprin g.java:44)
at TestSqliteUsingSpring.main(TestSqliteUsingSpring.j ava:19)
Caused by: java.sql.SQLException: getTime failed on value ( {0} ) in column {1} no conversion available12901443977182
at com.sun.rowset.CachedRowSetImpl.getTimestamp(Unkno wn Source)
at com.sun.rowset.CachedRowSetImpl.getTimestamp(Unkno wn Source)
at org.springframework.jdbc.support.rowset.ResultSetW rappingSqlRowSet.getTimestamp(ResultSetWrappingSql RowSet.java:515)
Attachments:
- Spring-Implementation.PNG (55.94 kB)
- SqliteDriverImplementation.PNG (52.15 kB)
- TestSqliteUsingSpring.java (2.18 kB)