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 "FilterQueryGuidance" by ShalinMangar
Date Fri, 12 Jun 2009 15:39:29 GMT
Dear Wiki user,

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

The following page has been changed by ShalinMangar:
http://wiki.apache.org/solr/FilterQueryGuidance

The comment on the change is:
Added notes on analysis, scoring and faceting

------------------------------------------------------------------------------
  Anyway, we need to analyze, to decompose the queries we want our system to handle.
  We'll then know the query parts and the frequency of the various combinations,
  and we'll then see what are good filter query candidates.
+ 
+ == Analysis, Scoring and Faceting ==
+ 
+ Each field type in Solr can define a index-time and query-time analyzer. When a query is
specified through the 'q' parameter, it is parsed and the token is analyzed through the query-time
analyzer for that field's type. For example, 'string' type fields are not analyzer but 'text'
type fields are analyzed. However, any query specified as a filter query through the 'fq'
parameter is *not* analyzed regardless of the field's type. Therefore, filter queries are
best suited for filtering on exact matches or range searches. If you need to filter but the
search query needs to be analyzed, it should be specified through the 'q' parameter.
+ 
+ Filter queries, as the name suggest, are used for filtering (or drilling down) the result
set. Therefore, the results of a filter does not need to be ordered and hence it does not
participate in the scoring. Queries specified in the 'q' parameter contribute to the scores.
+ 
+ Filter queries are great for filtering result sets based on facets. Faceting is performed
on the indexed tokens and therefore the value of any facet can be directly used in the 'fq'
parameter since it does not need to be analyzed.
  
  == An example to illustrate the greater efficiency obtainable by filtering ==
  

Mime
View raw message