Organizational Research By

Surprising Reserch Topic

Solr filter out facet results individually?

i am working on filtering out facet returned by solr based on predefined list of criterias.

for example i am querying for do*****ents that are of different types. the facet returned is as follows:

    2304 2277 1550 598 471 446 445 435 426 418 411 375 375 328 308 272

lets say i want not show microsoft as a result for this facet_field. the query currently looked like the following. i have give some try with tag and exclusion filters but im out of luck...


edit my current solution was to add a custom search handler and perform the filtering post-query *****. i would like to have a solution through the query mechanism this way would involve less processing.

asked May 16, 2015 in SOLR by rajesh
0 votes

Related Hot Questions

1 Answer

0 votes
have you ever tried the "facet.query" parameter? if i have understood your problem correctly, if you put a facet.query=-applicationname:microsoft on your request, solr will do exactly what you want. so, it should be like:

edit:the above hint is wrong. it will only return the number of do*****ents that don't have "microsoft" on the field "applicationname".

you should put the same query on your "q" parameter. just like that:

answered May 16, 2015 by rajesh