Most efficient way to return range between the Min and Max values of a fields
What would be the best way to retrieve the range between the Max and Min values of a specific field in the index?
The only thing that comes to my mind is to send to GroupByRequest with two opposite sort, then add my own logic to calculate the range.
Any way to make this more efficient?
A group by request on the field, with :
generateAutomaticRange = true
maximumNumberOfValues = 1
queryOverride = "@uri"
Should do the trick.