Maybe the scripted fields could be disabled in Elasticsearch.yml? I don't have access to it, it's in the cloud and only the cloud guys have access. I already requested him to take a look at it for me. Do you think this could be the issue?
So this is completely different. What you were working on is a query using painless. Scripted fields are a little different.
In here you write just painless/java. Click on Get help with the syntax and preview the results of your script. at the bottom of the page and it can help you out some.
But to access data you use doc['some_field'].value and replace with the correct field name. When you get to the result you just do a return.
Are you trying to make a new field with the text succeeded if the some value of a field is 0? If so then you can do a static lookup that kind of looks like this. You just need to replace some_field with the field name that contains the field that you are evaluating.
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant
logo are trademarks of the
Apache Software Foundation
in the United States and/or other countries.