如何在OrientDB 2.2.x中查询location "within" Spatial Module in Java?
How to query location "within" in OrientDB 2.2.x Spatial Module in Java?
我正在尝试实现 OrientDB 空间模块,需要一些帮助来在 Java 中对其进行编码。
如何在 Java 中执行等效查询:
select *,ST_Distance_Sphere(location,ST_GeomFromText('POINT(12.4696635 41.8894657)')) as distance from Points where ST_Distance_Sphere(location,ST_GeomFromText('POINT(12.4696635 41.8894657)')) < 200 order by distance
谢谢!
唯一的方法是使用 OSQL:
List<ODocument> execute = db.query(new OSQLSynchQuery<ODocument>(
"select *,ST_Distance_Sphere(location,ST_GeomFromText('POINT(12.4696635 41.8894657)')) as distance from Points where ST_Distance_Sphere (location,ST_GeomFromText('POINT(12.4696635 41.8894657)')) < 200 order by distance"));
有帮助吗?
我正在尝试实现 OrientDB 空间模块,需要一些帮助来在 Java 中对其进行编码。
如何在 Java 中执行等效查询:
select *,ST_Distance_Sphere(location,ST_GeomFromText('POINT(12.4696635 41.8894657)')) as distance from Points where ST_Distance_Sphere(location,ST_GeomFromText('POINT(12.4696635 41.8894657)')) < 200 order by distance
谢谢!
唯一的方法是使用 OSQL:
List<ODocument> execute = db.query(new OSQLSynchQuery<ODocument>(
"select *,ST_Distance_Sphere(location,ST_GeomFromText('POINT(12.4696635 41.8894657)')) as distance from Points where ST_Distance_Sphere (location,ST_GeomFromText('POINT(12.4696635 41.8894657)')) < 200 order by distance"));
有帮助吗?