是否可以使用线性或多边形地理类型的geo_distance查询? [英] Is a geo_distance query with linestring or multipolygon geo type possible?

查看:124
本文介绍了是否可以使用线性或多边形地理类型的geo_distance查询?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我没有找到任何这样的例子,但是我有多面体形状(并且一旦我想出这一点,它将在线上操作)存储在ES中,并且需要找到多边形(或线串)的最近点从给定的一点。



这甚至是ES吗?



TIA。

解决方案

目前,ES只支持形状的基本操作。这意味着如果形状不相交,相交,或者 另一个。到目前为止,geo_shapes之间的距离无法计算。为了能够解决您的问题,您需要将形状控制点分别作为geo_points进行索引,并按距离进行过滤。
我认为在不久的将来ES将至少支持计算形状之间的距离。



干杯,
Florian


I have not been able to find any examples of this, but I have multipolygon shapes (and will be operating on linestrings once I figure this out) stored in ES and need to find the closest point of the multipolygon (or linestring) from a given point.

Is this even possible ES?

TIA.

解决方案

at the moment ES just supports the basic operations on shapes. This means if shapes are disjoint, intersect or if one lies within another. Distances between geo_shapes could not be calculated so far. To be able to solve you problem, you need to index the shapes control points separately as geo_points and filter these by distance. I think in the near future ES will at least support calculation of distances between shapes.

Cheers, Florian

这篇关于是否可以使用线性或多边形地理类型的geo_distance查询?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆