diff --git a/solr/CHANGES.txt b/solr/CHANGES.txt index b6b4d845910..ce1955e074d 100644 --- a/solr/CHANGES.txt +++ b/solr/CHANGES.txt @@ -260,6 +260,9 @@ Bug Fixes * SOLR-4788: Multiple Entities DIH delta import: dataimporter.[entityName].last_index_time is empty. (chakming wong, James Dyer via shalin) +* SOLR-4978: Time is stripped from datetime column when imported into Solr date field + if convertType=true. (Bill Au, shalin) + Optimizations ---------------------- diff --git a/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/JdbcDataSource.java b/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/JdbcDataSource.java index b3a0e9c7cd7..41bc126d93b 100644 --- a/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/JdbcDataSource.java +++ b/solr/contrib/dataimporthandler/src/java/org/apache/solr/handler/dataimport/JdbcDataSource.java @@ -333,7 +333,7 @@ public class JdbcDataSource extends result.put(colName, resultSet.getDouble(colName)); break; case Types.DATE: - result.put(colName, resultSet.getDate(colName)); + result.put(colName, resultSet.getTimestamp(colName)); break; case Types.BOOLEAN: result.put(colName, resultSet.getBoolean(colName));