I want to create a new scripted field using existing scripted fields in kibana but my scripting is throwing null pointer exception .
Two script fields, total_hours and new_hours.
I want difference of these two as new scripting field.
I want to create a new scripted field using existing scripted fields in kibana but my scripting is throwing null pointer exception .
Two script fields, total_hours and new_hours.
I want difference of these two as new scripting field.
Hi,
that doesn't work unfortunately. You can't get access to another scripted field inside a scripted field (since that way Elasticsearch would need to know in which order to compile them and you could end up with cyclic dependencies). You'll basically need to copy over the script of those 2 fields, and use them directly in the third field you want to create.
Cheers,
Tim
Thank you for answer. But, copying the scripts of two script fields and use in third field does not have increase the load? Do we have any tips to avoid performance issues here?
It will slightly increase the load, but it depends on how complex those scripts are.
This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
© 2020. All Rights Reserved - Elasticsearch
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.