Hi,
My document looks like this
{
"branchCode":"WA-0104556",
"items":[
{
"id":"CAR-0014",
"qty":4,
"category":"PRIMARY"
},
{
"id":"CAR-0015",
"qty":5,
"category":"PRIMARY"
},
{
"id":"CAR-0016",
"qty":4,
"category":"MISCELLANNEOUS"
}
]
}
how do I query for something like:
- Get me all documents whose NONE of its items' "category" is PRIMARY
- Get me all documents whose ANY of its items' "category" is MISCELLANEOUS
is there any special way when uploading the document to ES? what's the datatype and index type for the field "items"? The document structure shown above is structure in DB, not ES.
ES index is not yet created for this one.
thanks