Py学习  »  Elasticsearch

在Elasticsearch中使用from/size-“滚动上下文中不允许使用[from]

Will Taylor • 4 年前 • 2667 次点击  

我的问题:

            {
                "query": {
                  "bool": {
                      "should": [
                          { "match": { "object.id": query } },
                          { "match": { "object.name": query } },
                          { "match": { "object.content": query } },
                          { "match": { "object.type": query } }
                      ]
                  }
                },
                "_source": "object.*",
                "from" : from_result,
                "size": RESULTS_PER_PAGE
            }

返回的错误为:

b'{"error": {"root_cause": [{"type": "action_request_validation_exception", "reason": "Validation Failed: 1: using [from] is not allowed in a scroll context;"}], "type": "action_request_validation_exception", "reason": "Validation Failed: 1: using [from] is not allowed in a scroll context;"}, "status": 400}'
Python社区是高质量的Python/Django开发社区
本文地址:http://www.python88.com/topic/55068
 
2667 次点击