-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Closed
Milestone
Description
According to the ES docs here:
Geo distance sorting should support sort_mode options min, max and avg. I have a scenario where my documents contain a field which is a collection of geo_points, and I need to sort by either min or max distance from origin under various conditions.
I'm using
query.SortGeoDistance(s => s
.OnField(f => f.GeoLocations)
.PinTo(-84.0, 39.0)
.Unit(GeoUnit.Miles)
.Ascending());
but so far have not found a way to apply the Min or Max modes to the geo sort. Locally I've modified the SortGeoDistanceDescriptor class to add mode support which is working fine, but I wanted to check to see if I was missing something that's already there.
Is there already a way to apply sort mode to SortGeoDistance?
Thanks!
Metadata
Metadata
Assignees
Labels
No labels