2
votes

I've noticed something curious with our SOLR 7 results. We have faceting enabled on, for example, a manufacturer field. When a search is performed for a particular manufacturer, the facet data will include a number of results for that manufacturer (in this case, 99 results). Also, all the facet results add up to match the total number of documents matching the query (which makes sense).

If a "blank" search is performed (resulting in a : query), all documents are returned from SOLR (~242,000). The facet results for the manufacturer field are no longer adding up to the total number of documents returned, however. It ends up being ~36,000 documents short. The specific manufacturer that I searched for in the prior example, which DID return a count of 99 in the facet data for that manufacturer, now returns nothing for that manufacturer. There is no facet result shown for that manufacturer.

If I query solr for the specific manufacturer value in the specific field we're faceting on, then it finds the 99 matches, and the facet data also shows the 99 results.

I think this problem is only happening when a : (or blank q) query is done.

Any suggestions?

Please let me know if you require more information. Thanks, Bill

1
Please refer - wiki.apache.org/solr/SimpleFacetParameters#facet.limit if you have not already. Based on this try giving a negative value to see if it helps you getting correct facet results.Amit
Thanks @Amit. The facet.limit was what I needed.user3302110

1 Answers

2
votes

I'm not sure I get your problem true but I suggest you some typical solution.

you can use "enum" facet method for huge facets.

 facet.method=enum

Furthermore you need to control facet counts with:

facet.limit=10000   //maximum number of returned facets
facet.offset= 0 

for more information about Solr facet params go to: https://wiki.apache.org/solr/SimpleFacetParameters