Complicated Nested Query

Hi Guys Please suggest a query or approach for this problem below Here I have two records in my type called "journey"

Record 1

{
"journeyid":1,
"journeyname":"test1",
"journeydetail:[
{
"pickupcode":"Banglore",
"deliverycode":" Maharastra"
},
{
"pickupcode":"Delhi"
"deliverycode":" Lucknow"
}]
}

Record2

{
"journeyid":2,
"journeyname":"test2",
"journeydetail:[
{
"pickupcode":"Banglore",
"deliverycode":"Kerala"
}
]
}
Input
I have added pickupcode:banglore in my excluded list

Expected result
Record 1 only show because it contains two nested object where banglore has only restriction and other cities delhi and lucknow has accessible. So that record must show

Record 2 should not show beacuse it has only one object there banglore is restricted

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.