Hello,World

哪个大神知道这个错误是什么导致的?是在更新文档的时候报的错误

Elasticsearch | 作者 dorisnzy | 发布于2018年06月07日 | 阅读数:9033

{"error":{"root_cause":[{"type":"action_request_validation_exception","reason":"Validation Failed: 1: script or doc is missing;"}],"type":"action_request_validation_exception","reason":"Validation Failed: 1: script or doc is missing;"},"status":400}
已邀请:

strglee

赞同来自: vearne aotiyou

更新的时候需要script 或者doc 
 
POST /website/blog/1/_update
{
"doc" : {
"tags" : [ "testing" ],
"views": 0
}
}

OR

POST /website/blog/1/_update
{
"script" : "ctx._source.views+=1"
}

https://www.elastic.co/guide/c ... .html

要回复问题请先登录注册