Hi Yonik, I’ve been working on [SOLR-5743] Faceting with BlockJoin support <https://issues.apache.org/jira/browse/SOLR-5743>, and I think it would be nice to integrate this functionality into JSON Facet API. Current JSON options <http://yonik.com/solr-nested-objects/> provide either querying child documents and faceting on parent ones, or vice versa, i.e. querying parent documents and calculating facets on all their children. But for typical eCommerce product/sku navigation it’s important to query parent documents that have some specific children (using ToParentBlockJoinQuery) and calculate correspondent facets. I.e. we need to calculate number of parent documents that have matched children with particular attributes. In example, provided on http://yonik.com/solr-nested-objects/, let’s suppose that user searches books that have 5 star reviews and wants to have a facet by authors with number of books (i.e. reviewing the same book again is not counted).
It looks like neither blockChildren nor blockParent suite for this use case. Do you have an idea of how to extend JSON facets to cover such usage? Oleg
