Parent Id Usageedit

The parent_id query can be used to find child documents which belong to a particular parent.

See the Elasticsearch documentation on parent_id query for more details.

Fluent DSL Exampleedit

q
.ParentId(p => p
    .Name("named_query")
    .Type<Developer>()
    .Id(Project.Projects.First().Name)
)

Object Initializer Syntax Exampleedit

new ParentIdQuery
{
    Name = "named_query",
    Type = Infer.Type<Developer>(),
    Id = Project.Projects.First().Name
}

Example json output. 

{
  "parent_id": {
    "_name": "named_query",
    "type": "developer",
    "id": "Lesch Group"
  }
}