Hi,
I can't found any good example how use Join function with Solrj 4.0 api.
Let's have this example data:
<doc>
<field name="id">1</field>
<field name="name">Thomas</field>
<field name="age">40</field>
</doc>
<doc>
<field name="id">2</field>
<field name="name">John</field>
<field name="age">17</field>
<field name="parent">1</field>
</doc>
And code:
String stringQuery = "(name:Thomas) AND (age:40)";
SolrQuery query = new SolrQuery();
query.setQuery(stringQuery);
QueryResponse response = solrServer.query(query);
Result is doc with id=1. Now I want extend query above with JOIN similar
to this:
{!join from=to=idparent }(name:John AND age:17)
and expect same result - doc with id=1. But I have no idea how add this
Join condition to SolrQuery object. Is there any method I missed? Or
must I extend my base stringQuery somehow?
Thanks for any advice!
Roman