No option for updating field using string
I was trying to update a document with help of a script but didn't find a way through which we can do this.
The same queries in kibana work as expected. But whenever I add a script in app-search API it just adds another field named "script" and adds the script in a stringified format as its value.
Can you post an example or something? I don't think I understand what you're asking.
Elastic Search provides this functionality out of the box, to update or get documents by running some script on the documents while querying.
POST test/_update/1
{
"script" : {
"source": "ctx._source.counter += params.count",
"lang": "painless",
"params" : {
"count" : 4
}
}
}
I am able to perform the above query using Elastic Search API's, but I am specifically using Elastic App Search and it also provides API which has different endpoints than ElasticSearch App. But the script isn't working when I use App Search Endpoints.
This WORKS: https://imgur.com/a/0QLhAPZ This DOESN'T: https://imgur.com/a/WbtX58E