thank you very much :-)
2014-07-22 16:34 GMT+02:00 Umesh Prasad :
> public static DocSet mapChildDocsToParentOnly(DocSet childDocSet) {
>
> DocSet mappedParentDocSet = new BitDocSet();
> DocIterator childIterator = childDocSet.iterator();
> while (childIterator.hasNext
public static DocSet mapChildDocsToParentOnly(DocSet childDocSet) {
DocSet mappedParentDocSet = new BitDocSet();
DocIterator childIterator = childDocSet.iterator();
while (childIterator.hasNext()) {
int childDoc = childIterator.nextDoc();
int par
Query parentFilterQuery = new TermQuery(new Term("document_type",
"parent"));
int[] childToParentDocMapping = new int[searcher.maxDoc()];
DocSet allParentDocSet = searcher.getDocSet(parentFilterQuery);
DocIterator iter = allParentDocSet.iterator();
Thanks, Umesh
You can get the parent bitset by running a the parent doc type query on
> the solr indexsearcher.
> Then child bitset by runnning the child doc type query. Then use these
> together to create a int[] where int[i] = parent of i.
>
Can you kindly add an example? I am not quite sure h
Comments inline
On 16 July 2014 20:31, Bjørn Axelsen
wrote:
> Hi Solr users
>
> I would appreciate your inputs on how to handle a *mix *of *simple *and
> *nested
> *documents in the most easy and flexible way.
>
> I need to handle:
>
>- simple documens: webpages, short articles etc. (approx
Hi Solr users
I would appreciate your inputs on how to handle a *mix *of *simple *and *nested
*documents in the most easy and flexible way.
I need to handle:
- simple documens: webpages, short articles etc. (approx. 90% of the
content)
- nested documents: books containing chapters etc.