O'Reilly logo

Apache Solr 3 Enterprise Search Server by Eric Pugh, David Smiley

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Facet queries

This is the final type of faceting, and it offers a lot of flexibility. Instead of choosing a field to facet its values on or faceting a specified range of values, we specify some number of Solr queries that each itself becomes a facet. For each facet query specified, the number of documents matching the facet query that also match the main search is counted. Each facet query with its facet count is returned in the results under the facet_queries section. Facet queries are each cached in the filter cache .

There is only one parameter for configuring facet queries:

  • facet.query: A Solr query to be evaluated over the search results. The number of matching documents (the facet count) is returned as an entry in the results next to this ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required