You are viewing a plain text version of this content. The canonical link for it is here.
Posted to solr-user@lucene.apache.org by Jens Flaaris <jj...@saxotech.com> on 2011/04/28 09:09:53 UTC

XS DateTime format

Hi,

I just have a small question regarding the output format of fields of type TrieDateField. If a document containing the date 0001-01-01T01.01.01Z is passed to Solr and I then try to search for that document the output of the date field is of format Y-MM-DDThh:mm:ssZ. The first three zeros are missing. According to XML specification found on w3.org yyyy in XS DateTime is a four-or-more digit optionally negative-signed numeral that represents the year. Is it intentional that Solr strips leading zeros for the first four digits?

Thanks
Jens Jørgen Flaaris

Re: XS DateTime format

Posted by Chris Hostetter <ho...@fucit.org>.
: negative-signed numeral that represents the year. Is it intentional that 
: Solr strips leading zeros for the first four digits?

No, it's a really stupid bug, due to some really stupid date formatting i 
haven't had a chance to refactor out of existence...

	https://issues.apache.org/jira/browse/SOLR-1899




-Hoss