I need to find the average of Result (vResultAttribute column is saved in elastic as a string) of each subject for each student.
How can we do this in elastic?
I would recommend restructuring how you model your data. Maybe breaking up the example you provided into multiple documents with the following structure during indexing could make querying easier?
I mean, without restructuring is it possible (With string data)
with the help of JSON processor to convert string to json object and then apply aggregations
Given that you likely need to use a script to parse the JSON string and also have a nested structure, I suspect it would not be straightforward, but I can't say whether it is possible or not. Maybe someone else have done something similar in the past and can assist?
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.