lucene-solr-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Apache Wiki <wikidi...@apache.org>
Subject [Solr Wiki] Update of "FieldCollapsing" by martijnvg
Date Fri, 17 Jun 2011 23:07:47 GMT
Dear Wiki user,

You have subscribed to a wiki page or wiki category on "Solr Wiki" for change notification.

The "FieldCollapsing" page has been changed by martijnvg:
http://wiki.apache.org/solr/FieldCollapsing?action=diff&rev1=33&rev2=34

- <!> [[Solr4.0]]
+ <!> [[Solr4.0]]  <!> [[Solr3.3]]
  
  = Result Grouping / Field Collapsing =
  <<TableOfContents>>
@@ -13, +13 @@

  Result Grouping groups documents with a common field value into groups, returning the top
documents per group, and the top groups based on what documents are in the groups.  One example
is a search at Best Buy for a common term such as DVD, that shows the top 3 results for each
category ("TVs & Video","Movies","Computers", etc)
  
  = Quick Start =
- If you haven't already, get a recent nightly build of [[Solr4.0]], start the example server
and index the example data as shown in the [[http://lucene.apache.org/solr/tutorial.html|solr
tutorial]].
+ If you haven't already, get a recent nightly build of [[Solr4.0]] or [[Solr3.3]], start
the example server and index the example data as shown in the [[http://lucene.apache.org/solr/tutorial.html|solr
tutorial]].
  
  Now send a query request to solr and turn on result grouping.  We'll first try grouping
on the manufacturer name (the manu_exact field). <!> You can currently only group on
single-valued fields!
  
@@ -133, +133 @@

  = Request Parameters =
  ||'''param name''' ||'''param value'''||'''description''' ||
  ||group||true/false||if true, turn on result grouping||
- ||group.field||[fieldname]||Group based on the unique values of a field.  The field must
currently be single-valued and must be either indexed, or be another field type that has a
value source and works in a function query - such as [[http://lucene.apache.org/solr/api/org/apache/solr/schema/ExternalFileField.html|ExternalFileField]]||
+ ||group.field||[fieldname]||Group based on the unique values of a field.  The field must
currently be single-valued and must be either indexed, or be another field type that has a
value source and works in a function query - such as [[http://lucene.apache.org/solr/api/org/apache/solr/schema/ExternalFileField.html|ExternalFileField]].
Note: for Solr 3.3 the field must by a string like field such as StrField or TextField, otherwise
a http status 400 is returned.||
- ||group.func||[function query]||Group based on the unique values of a function query.||
+ ||group.func||[function query]||Group based on the unique values of a function query. <!>
[[Solr4.0]] This parameter only is supported on 4.0||
  ||group.query||[query]||Return a single group of documents that also match the given query.||
  ||rows||[number]||The number of groups to return. Defaults to 10.||
  ||start||[number]||The offset into the list of groups.||
@@ -145, +145 @@

  ||group.format||grouped/simple||if simple, the grouped documents are presented in a single
flat list.  The start and rows parameters refer to numbers of documents instead of numbers
of groups.||
  ||group.main||true/false||If true, the result of the first field grouping command is used
as the main result list in the response, using group.format=simple||
  ||group.ngroups||true/false||If true, includes the number of groups that have matched the
query. Default is false.||
- ||group.cache.percent||[0-100]||If > 0 enables grouping cache. Grouping is executed actual
two searches. This option caches the second search. A value of 0 disables grouping caching.
Default is 0.||
+ ||group.cache.percent||[0-100]||If > 0 enables grouping cache. Grouping is executed actual
two searches. This option caches the second search. A value of 0 disables grouping caching.
Default is 0. Tests have shown that this cache only improves search time with boolean queries,
wildcard queries and fuzzy queries. For simple queries like a term query or a match all query
this cache has a negative impact on performance||
  
  
  Notes:

Mime
View raw message