Search for docs that are parents

Hi There,

I'm looking for a way to search for documents where the join field specifies that they are a parent, that way I can still search for parents without children?

Here's my very crude attempt which fails...

POST /families/_search
{
  "query": {
    "term": {
    "family": { # this is the join field
      "name": "father"
    }
  }
}
}

Any help would be much appreciated, thanks!

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