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 Timothy Potter <th...@gmail.com> on 2016/07/18 14:02:47 UTC

DateMath parsing change?

I have code that uses the DateMathParser and this used to work in 5.x
but is no longer accepted in 6.x:

time:[NOW-2DAY TO 2016-07-19Z]

org.apache.solr.common.SolrException: Invalid Date in Date Math
String:'2016-07-19Z'
at org.apache.solr.util.DateMathParser.parseMath(DateMathParser.java:241)

This is in a unit test, so I can change it, but seems like regression to me?

Re: DateMath parsing change?

Posted by Timothy Potter <th...@gmail.com>.
Got an answer from Hossman in another channel ... this syntax was not
officially supported and is no longer valid, i.e. my code must change
;-)

On Mon, Jul 18, 2016 at 8:02 AM, Timothy Potter <th...@gmail.com> wrote:
> I have code that uses the DateMathParser and this used to work in 5.x
> but is no longer accepted in 6.x:
>
> time:[NOW-2DAY TO 2016-07-19Z]
>
> org.apache.solr.common.SolrException: Invalid Date in Date Math
> String:'2016-07-19Z'
> at org.apache.solr.util.DateMathParser.parseMath(DateMathParser.java:241)
>
> This is in a unit test, so I can change it, but seems like regression to me?