title: Querying nested document Elasticsearch
body: <p>I am learning Elasticsearch so I am not sure if this query is correct. I have checked that the data is indexed, but I don't get any hits. What am I doing wrong? Shouldn't this get a hit on a car where the creator's name is steve?</p>
  
  <pre><code>builder
  .startObject()
      .startObject("car")
          .field("type", "nested")
          .startObject("properties")
              .startObject("creators")
                  .field("type", "nested")                    
              .endObject()                
          .endObject()
      .endObject()
  .endObject();
  
  
  {
    "query": {
      "bool": {
        "must": [
          {
            "term": {
              "car.creators.name": "Steve"
            }
          }
        ],
        "must_not": [],
        "should": []
      }
    },
    "from": 0,
    "size": 50,
    "sort": [],
    "facets": {}
  }
  </code></pre>