title: ElasticSearch Pagination & Sorting
body: <p>I am trying to sort search results by a date across multiple pages of results. Sorting is working within each page, is there a way to sort across the entire set?</p>
  
  <p>For example: If page 1 has items from Feb 13 through Feb 1st; the second page should not have items after Feb 1st.</p>
  
  <p>Here is a brief snippet of the request that I am sending. I have also tried sorting by date then _score, but that produced even stranger results (primarily, the sort order was the same).</p>
  
  <pre><code>{
    "query": {
      "from": 0,
      "size": 24
      "sort": [
        "published_on": {
          "missing": "_last",
          "ignore_unmapped": true,
          "order": "desc"
        }
      ]
      "custom_filters_score": {
        "query": {
          "bool": {
            "must": [
              {
                "match": {
                  "content": "Some query"
                }
              }
            ]
            ... more ...
          }
        },
        "filters": [
          {
            "filter" =&gt; {
              "type" =&gt; {
                "value" =&gt; "cats"
              }
            },
            "boost" =&gt; 2
          }
          ... more ...
        ]
      }
    }
  }
  </code></pre>
  
  <p>Any thoughts? Thanks in advance!</p>