I am trying to search the Azure Search Index for documents that are not just within x km of the search reference point but also where the document + y km is within x km of the search reference. y is a field on the document so it will be different for each document in the index.
相关问题
- running headless chrome in an microsoft azure web
- Docker task in Azure devops won't accept "$(pw
- Register MicroServices in Azure Active Directory (
- Removing VHD's from Azure Resource Manager aft
- Cannot use the Knowledge academic API
相关文章
- SQL Azure Reset autoincrement
- How to cast Azure DocumentDB Document class to my
- Can't get azure web role to run locally using
- Azure WebApp - Unable to auto-detect the runtime s
- How to change region for Azure WebSite
- Azure webjob vs cloud service
- Azure data transfer Identity Column Seed Jumped by
- Download Azure web app?
To find filter based on the distance between a reference point and a point given by a field in the document, you can use the geo.distance function in your $filter query. For instance if your geo point was in the field "location", you could filter to all results that are within 10km of that point with the following clause:
Azure Search also supports geo filtering by specifying a bounding polygon using the geo.intersects function:
If you're looking for something like
geo.distance(...) lt someOtherField
that is currently unsupported.From your question it sounds like you have a field in the document, and a static point that you'd like to check against, filtering by all documents that are within a certain range. This should be achievable with geo.distance. If this doesn't cover your scenario, can you provide more details and perhaps a concrete example of the problem you're trying to solve?
You can find more information about odata filtering using geo.distance and geo.intersects in the Azure Search OData syntax documentation