[ 
https://issues.apache.org/jira/browse/SOLR-5027?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13846567#comment-13846567
 ] 

Joel Bernstein edited comment on SOLR-5027 at 12/12/13 6:39 PM:
----------------------------------------------------------------

Deepak,

I tested with the CollapsingQParserPlugin in SOLR-5416 and I wasn't able to 
reproduce the bugs.

Both the sort ordering seems to be working and the I'm not getting the 
exception. The test I'm using incorporates: 
collapsing with max=float_field, 
implied ordering by score, 
fl with score,
faceting with tag and exclude 

{code}
   params = new ModifiableSolrParams();
   params.add("q", "*:*");
   params.add("fq", "{!collapse field=group_s max=test_tf}");
   params.add("defType", "edismax");
   params.add("bf", "field(id)");
   params.add("fl", "score, id");
   params.add("facet","true");
   params.add("fq", "{!tag=test}term_s:YYYY");
   params.add("facet.field", "{!ex=test}term_s");

    assertQ(req(params), "*[count(//doc)=2]",
        "//result/doc[1]/float[@name='id'][.='5.0']",
        "//result/doc[2]/float[@name='id'][.='1.0']");

{code}


was (Author: joel.bernstein):
Deepak,

I tested with the CollapsingQParserPlugin in SOLR-5416 and I wasn't able to 
reproduce the bugs.

Both the sort ordering seems to be working and the I'm net getting the 
exception. The test I'm using incorporates: 
collapsing with max=float_field, 
implied ordering by score, 
fl with score,
faceting with tag and exclude 

{code}
   params = new ModifiableSolrParams();
   params.add("q", "*:*");
   params.add("fq", "{!collapse field=group_s max=test_tf}");
   params.add("defType", "edismax");
   params.add("bf", "field(id)");
   params.add("fl", "score, id");
   params.add("facet","true");
   params.add("fq", "{!tag=test}term_s:YYYY");
   params.add("facet.field", "{!ex=test}term_s");

    assertQ(req(params), "*[count(//doc)=2]",
        "//result/doc[1]/float[@name='id'][.='5.0']",
        "//result/doc[2]/float[@name='id'][.='1.0']");

{code}

> Field Collapsing PostFilter
> ---------------------------
>
>                 Key: SOLR-5027
>                 URL: https://issues.apache.org/jira/browse/SOLR-5027
>             Project: Solr
>          Issue Type: New Feature
>          Components: search
>    Affects Versions: 5.0
>            Reporter: Joel Bernstein
>            Assignee: Joel Bernstein
>            Priority: Minor
>             Fix For: 4.6, 5.0
>
>         Attachments: SOLR-5027.patch, SOLR-5027.patch, SOLR-5027.patch, 
> SOLR-5027.patch, SOLR-5027.patch, SOLR-5027.patch, SOLR-5027.patch, 
> SOLR-5027.patch, SOLR-5027.patch
>
>
> This ticket introduces the *CollapsingQParserPlugin* 
> The *CollapsingQParserPlugin* is a PostFilter that performs field collapsing. 
> This is a high performance alternative to standard Solr field collapsing 
> (with *ngroups*) when the number of distinct groups in the result set is high.
> For example in one performance test, a search with 10 million full results 
> and 1 million collapsed groups:
> Standard grouping with ngroups : 17 seconds.
> CollapsingQParserPlugin: 300 milli-seconds.
> Sample syntax:
> Collapse based on the highest scoring document:
> {code}
> fq=(!collapse field=<field_name>}
> {code}
> Collapse based on the min value of a numeric field:
> {code}
> fq={!collapse field=<field_name> min=<field_name>}
> {code}
> Collapse based on the max value of a numeric field:
> {code}
> fq={!collapse field=<field_name> max=<field_name>}
> {code}
> Collapse with a null policy:
> {code}
> fq={!collapse field=<field_name> nullPolicy=<null_policy>}
> {code}
> There are three null policies:
> ignore : removes docs with a null value in the collapse field (default).
> expand : treats each doc with a null value in the collapse field as a 
> separate group.
> collapse : collapses all docs with a null value into a single group using 
> either highest score, or min/max.
> The CollapsingQParserPlugin also fully supports the QueryElevationComponent
> *Note:*  The July 16 patch also includes and ExpandComponent that expands the 
> collapsed groups for the current search result page. This functionality will 
> be moved to it's own ticket.



--
This message was sent by Atlassian JIRA
(v6.1.4#6159)

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org
For additional commands, e-mail: dev-h...@lucene.apache.org

Reply via email to