I have an index that looks something like this:
{
field:'value',
// ... more fields ...
prices: [{"date":"2016-01-01", "nights":1, "price":300},...]
}
The prices
array can contain around 10,000 entries per document.
I have a search query that will fetch all documents were the date
and nights
and price
values all meet some requirements like "where date is X, nights is Y and price is between A and B"
When I fetch the results, I have to exclude the prices
array from the source fields as it's way too big to be performant when retrieving 50 documents.
What I would like to do is retrieve the price entries that caused the doc to match in the first place.