We have multiple hotels and each hotel has diffirent price for different date which is also device specific. Now, if user search for a date range(11-04-2016 to 13-04-2016) then we need to get:
Hotel sorted against thier aggregate prices for the given dates for each device type.
I had kept prices, availability & dates within nested objects. Here are the gists for my current mappings, input data output & search query:
Aggregation Query & output:
Please help me to use aggregation to solve this problem or suggest any other solution for this.
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.