Scripts and scripted fields run in the context of a single document, so I do not see how it would help here. If you have a unique identifier that links these two entries, create a document with that as an ID and then update it so you get all data in a single document.
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.