Hi All, 

We are using solar 8.2 and wants to know if we can have nested subqueries.

 For ex. I have following types of documents in my collection. Different 
document types are stored . ( Not using nested documents  to avoid indexing 
overhead).
    
 {
    Id :111,
    docType: “HEADER”
    Value: “Header Document”
}

{
    id:222
    headerId :111,
    docType: “LINE”
    Value: “Line Document”
}

{
    Id :333,
    lineId:222
    docType: “SHIPMENT”
    Value: “Shipment Document”
}

If I have subquery in below fashion, I can get headers and lines. Lines as 
nested document.

http://localhost:9881/solr/order-coll-scmdt/select?q=id:111&fq=doc_type:HEADER&fl=id,docType,linessub:[subquery]
&linessub.q={!terms f=headerId 
v=$row.id}&linessub.fq=docType:LINE&linessub.fl=id,doc_type

We want to have further level of nesting where can also find shipments for each 
line , however this type of query does not work.

http://localhost:9881/solr/order-coll-scmdt/select?q=id:111&fq=doc_type:HEADER&fl=id,docType,linessub:[subquery]
&linessub.q={!terms f=headerId 
v=$row.id}&linessub.fq=docType:LINE&linessub.fl=id,doc_type,shipments:[subquery]
&shipments.q={!terms f=lineId v=$row.id}&shipments.fq=doc_type:SHIPMENT

Are there any limitations on nested subqueries? 

Any help on this is appreciated.

Thanks
Ravi

Reply via email to