I want to extend the solr schema in order to search for products that have a specific product attribute defined. I don't know for sure if this is possible because a product can have multiple product attributes and I only want to search on a value of a specific product attribute.
I guess I should add a property to the schema.xml like:
Code: Select all
<field name="productAttributes" type="text_general" indexed="true" stored="false" multiValued="true" />
Should I then create a new SearchFacet and use the ProductSearchFacet to search for that specific attribute value?
Code: Select all
List<SearchFacetDTO> availableFacets = searchService.getSearchFacets();
ProductSearchCriteria searchCriteria = facetService.buildSearchCriteria(request, availableFacets);
It would be great if this is possible.