title: How to include all docs in ElasticSearch Aggregation and avoid sum_other_doc_count > 0
body: <p>ES is not mainstream for my work, and there's one behavior I'm not able to correct. I have a fairly simple aggregation query:</p>
  
  <pre><code>GET /my_index/_search
  {
    "size": 0,
    "query": {
      "bool": {
        "must": [
          {
            "match": {
              "request_type": "some_type"
            }
          },
          {
            "match": {
              "carrier_name.keyword": "some_carrier"
            }
          }
        ]
      }
    },
    "aggs": {
      "by_date": {
        "terms": {
          "field": "date",
          "order": {
            "_term": "asc"
          }
        },
        "aggs": {
          "carrier_total": {
            "sum": {
              "field": "total_count"
            }
          }
        }
      }
    }
  }
  </code></pre>
  
  <p>My understanding from <a href="https://www.elastic.co/guide/en/elasticsearch/reference/current/search-aggregations-bucket-terms-aggregation.html" rel="nofollow noreferrer">https://www.elastic.co/guide/en/elasticsearch/reference/current/search-aggregations-bucket-terms-aggregation.html</a> is that not all documents are included in the aggregation. Indeed, depending on the query section, I do see in the results "sum_other_doc_count" : with values greater than zero.</p>
  
  <p>My question: is there a way to construct the search so that all docs are included? The number of documents is fairly small, typically under 1k, </p>
  
  <p>Thanks in advance,
  Reuven</p>