I have something like this one.
{
"title" : "",
"source" : {
"object" : "some",
"group" : "some
"data" : []
}
}
"source.data" or "source" can be undefined at all.
So now I need to select all objects that has count(xxx.source.data) > 0 . How can I do this query? I search for count() and xxx.length (method\property) but still can't understand how to use them in my case.
Added:
.find({"source.data": {$exists: true, $size: {$gt: 1}}})