tomerZZ
tomerZZ

Reputation: 21

Solr - multiple facet.field in query

I would like to add multiple facet.field (and also facet.count and other properties) to my Map to be used in SolrParams in a query but it only let you add one value per key (Java Map).

Can this be done?

Something like:

Map params = new Map();
params.put("facet.field", "title");
params.put("facet.field", "tags");
...
query(new SolrParams(params));

Upvotes: 0

Views: 1038

Answers (1)

Abhijit Bashetti
Abhijit Bashetti

Reputation: 8658

try this way

solrQuery.addFacetField(“subcat”)
solrQuery.addFacetField(“tags”)
solrQuery.addFacetField(“languages”)

Check the link for your reference Solr-using-Solr4J-in-Java.

Upvotes: 2

Related Questions