Yeah for a couple years we have wanted to know the number of values in a
facet field.

I.e.

facet.field=name&facet.limit=-1

But we only want to return 3, and we want to know how many names.

facet
facet.field = name
facet.field.name.count = 156
facet.field.name.1 = Bill, 8958
facet.field.name.2 = Tony, 7049
facet.field.name.3 = Sue, 5000

The facet.field.name.count is what we want. The issue is simple on one
machine, but with sharding and SolrCloud getting unique names is a
challenge. You either need to send the whole list to be deduped to get a
unique value or you get the unique count from each shard. The latter is
okay as long as each shard does not have duplicate fields... Then you can
add them.

Bill




On Wed, Jan 15, 2014 at 3:16 AM, yriveiro <yago.rive...@gmail.com> wrote:

> Hi,
>
> I'm wondering if Solr has some feature like face.mincount but for maxcount.
>
> I have an use case where I need to know what facets have less than n
> elements.
>
> I can do this adding the facet.limit=-1 parameter and fetch the whole set
> and client-side remove the elements that don't match the threshold. The
> problem is that the facet can return millions of rows and fetch the
> response
> and reduce the set can take a while ...
>
> /Yago
>
>
>
> -----
> Best regards
> --
> View this message in context:
> http://lucene.472066.n3.nabble.com/Facets-maxcount-feature-tp4111408.html
> Sent from the Solr - User mailing list archive at Nabble.com.
>



-- 
Bill Bell
billnb...@gmail.com
cell 720-256-8076

Reply via email to