Re: understanding collapsingQParser with facet vs group.facet

2015-06-22 Thread Joel Bernstein
The group head is the document from each group that was selected during the collapse. Only the group heads remain in the result set following the collapse. It looks like in the example above you have the basic idea correct. Joel Bernstein http://joelsolr.blogspot.com/ On Sat, Jun 20, 2015 at

Re: understanding collapsingQParser with facet vs group.facet

2015-06-19 Thread Derek Poh
Hi Upayavira Thank you for your explanation onthe difference between traditional grouping and collapsingQParser. I understand more now. On 6/19/2015 7:11 PM, Upayavira wrote: On Fri, Jun 19, 2015, at 06:20 AM, Derek Poh wrote: Hi I read about collapsingQParser returns the facet count the

Re: understanding collapsingQParser with facet vs group.facet

2015-06-19 Thread Derek Poh
Hi Joel By group heads, is it referring to the document thatis use to represent each group in the main result section? Eg. Using the below 3 documentsandwe collapse on field supplier_id supplier_id:S1 product_id:P1 supplier_id:S2 product_id:P2 supplier_id:S2 product_id:P3 With collapse on

understanding collapsingQParser with facet vs group.facet

2015-06-19 Thread Derek Poh
Hi I read about collapsingQParser returns the facet count the same as group.truncate=true and has this issue with the facet count and the after filter facet count notthe same. Using group.facetdoes not has this issue but it's performance is very badcompared to collapsingQParser. I trying to

Re: understanding collapsingQParser with facet vs group.facet

2015-06-19 Thread Upayavira
On Fri, Jun 19, 2015, at 06:20 AM, Derek Poh wrote: Hi I read about collapsingQParser returns the facet count the same as group.truncate=true and has this issue with the facet count and the after filter facet count notthe same. Using group.facetdoes not has this issue but it's performance

Re: understanding collapsingQParser with facet vs group.facet

2015-06-19 Thread Joel Bernstein
The CollapsingQParserPlugin currently doesn't calculate facets at all. It simply collapses the document set. The facets are then calculated only on the group heads. Grouping has special faceting code built into it that supports the group.facet functionality. Joel Bernstein

Re: understanding collapsingQParser with facet vs group.facet

2015-06-19 Thread Joel Bernstein
Unfortunately this won't give you group.facet results: q=whatever fq={!collapse tag=collapse}blah facet.field={!ex=collapse}my_facet_field This will give you the expanded facet counts as it removes the collapse filter. A good explanation of group.facets is here:

Re: understanding collapsingQParser with facet vs group.facet

2015-06-19 Thread Joel Bernstein
The AnalyticsQuery can be used to implement custom faceting modules. This would allow you to calculate facets counts in an algorithm similar to group.facets before the result set is collapsed. If you are in distributed mode you will also need to implement a merge strategy: