Apologies for cross posting a question from SO here.

I am very interested in the new faceting on child documents feature of Solr
5.3 and would like to know if somebody has figured out how to do it as
asked in the question on
http://stackoverflow.com/questions/32212949/solr-5-3-faceting-on-children-with-block-join-parser

Thanks for any hints,
Tom

The question is:

Solr 5.3 supports faceting on nested documents [1], with a great tutorial
from Yonik [2].

In the tutorial example, the query to get the documents for faceting is
directly performed on the child documents:

    $ curl http://localhost:8983/solr/demo/query -d '
    q=author_s:yonik&fl=id,comment_t&
    json.facet={
    genres : {
        type: terms,
        field: cat_s,
        domain: { blockParent : "type_s:book" }
    }
    }'

What I do not know is how to facet on child documents returned from a Block
Join Parent Query Parser [3] and provided through ExpandComponent [4].

What I have working so far is the same as in the example from the
ExpandComponent [4]: Query the child fields to return the parent documents
(see 1.), then expand the result to get the relevant child documents (see
2.)


    1. q={!parent which="type_s:parent" v='text_t:solr'}

    2. &expand=true&expand.field=ISBN_s&expand.q=*:*

What I need:

Having steps 1.) and 2.) already working, how can we facet on some field
(does not matter which) of the returned child documents from (2.) ?

  [1]: http://yonik.com/solr-5-3/
  [2]: http://yonik.com/solr-nested-objects/
  [3]: https://cwiki.apache.org/confluence/display/solr/Other+Parsers
  [4]: http://heliosearch.org/expand-block-join/

Reply via email to