Awesome! The surrounding braces did the thing. Fixed the quotes just before.
Many thanks!!

The remaining issue is that some source files in o.a.s.search.facet package are 
package protected or private. I can't implement a custom Agg using FacetContext 
and such. Created issue: https://issues.apache.org/jira/browse/SOLR-8673

Thanks again!
Markus
 
 
-----Original message-----
> From:Yonik Seeley <ysee...@gmail.com>
> Sent: Thursday 11th February 2016 17:12
> To: solr-user@lucene.apache.org
> Subject: Re: Json faceting, aggregate numeric field by day?
> 
> On Thu, Feb 11, 2016 at 11:07 AM, Markus Jelsma
> <markus.jel...@openindex.io> wrote:
> > Hi - i was sending the following value for json.facet:
> > json.facet=by_day:{type : range, start : NOW-30DAY/DAY, end : NOW/DAY, gap 
> > : "+1DAY", facet:{x : "avg(rank)"}}
> >
> > I now also notice i didn't include the time field. But adding it gives the 
> > same error:
> > json.facet=by_day:{type : range, field : time, start : NOW-30DAY/DAY, end : 
> > NOW/DAY, gap : "+1DAY", facet:{x : "avg(rank)"}}
> 
> Hmmm, the whole thing is a JSON object, so it needs curly braces
> around the whole thing...
> json.facet={by_day: [...] }
> 
> You may need quotes around the date specs as well (containing slashes,
> etc)... not sure if they will be parsed as a single string or not
> 
> -Yonik
> 

Reply via email to