es定制排序搜索结果

GET /company/employee/_search
{
  "query": {
    "constant_score": {
      "filter": {
        "range": {
          "age": {
            "gte": 30
          }
        }
      }
    }
  },
  "sort": [{
    "join_date": {
      "order": "asc"
    }
  }]
}

posted @ 2018-03-08 21:31  秦先生的客栈  Views(438)  Comments(0Edit  收藏  举报