On Mon, Oct 4, 2010 at 10:24 PM, Kouta Osabe <kota0919was...@gmail.com> wrote: > Hi,All > > I have a problem about Solr Date Field. [...]
> the value of pub_date column comes from MySQL and actually value is > "2010-10-05 00:00:00". > > I regist "foo" bean to Solr through SolrJ like "new > CommonsHttpSolrServer().addBean(foo)" > > I expected "2010-10-05 00:00:00" to display by Solr Admin but > "2010-10-04T15:00:00Z" displayed on Solr Admin. > > is this timezone problem?(I live in Tokyo Japan). [...] Yes, it is a timezone issue. Japan is UTC + 9h, which is the offset that you are seeing. As far as I know, Solr does not itself do any timezone conversion, but depends on the time retrieved by the driver. If you want UTC, instead of local time, you might want to look into getDate( columnName, Calendar ). Please see http://download.oracle.com/javase/1.4.2/docs/api/java/sql/ResultSet.html#getDate(int,%20java.util.Calendar) Regards, Gora