dongnguyenltqb
2/10/2020 - 3:31 AM

_update_by_query, for videoComments index elasctisearch

 POST /index/_update_by_query	
{
  "script": {
    "source": "ctx._source.isDisabledComment =false",
    "lang": "painless"
  },
  "query": {
    "match_all": {}
  }
}


## example
curl --location --request POST 'localhost:9200/academyvideos/_update_by_query' \
--header 'Content-Type: application/json' \
--data-raw '{
  "script": {
    "source": "ctx._source.isDisabledComment =false",
    "lang": "painless"
  },
  "query": {
    "match_all": {}
  }
}'