I have a product database, where products have a set delivery zones,
represented in elasticsearch as an array:
distance: double (in miles),
location: geohash (source location of product/seller),
does anyone have any idea how I can filter using the distance within the
I know the co-ordinates of my users, and I like to filter out products that
don't cannot be delivered to their location - in other words, where the
distance "double" field is greater than the distance between their
co-ordinates and the source co-ordinates of the product.
All the examples of goedistance filtering I've seen require the distance to
be provided in the query - not analysed from the document itself.
I'm not sure if I can use scripting to do this - if so, how?
Any help would be hugely appreciated!
You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to email@example.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/7cc7b619-f06e-4bd4-9da0-03dbf26e3b5c%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.