I'm trying to create a run-time field which creates an array. I've been doing simple things like creating strings based on a conditional field but I can't seem to get the right syntax for a multi-value string object. This is currently what I'm looking to do....
(this is done within Kibana)
if (doc['criteria.keyword'].value == 'condition') emit('result1','result2');
Expected result:
"test": [
"result1",
"result2"
]
The emit I've used below fires a syntax error about having more than one condition.
If you'd like further advice, please provide a reproducible test (for instance one request to index a document, and one search query with a runtime field)
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.