PostGIS ST_Intersects not returning values

المشرف العام

Administrator
طاقم الإدارة
I recently installed the PostGIS extension for a rails app that i'm working on. Currently, i am trying to get all the polygons that intersect the vieport of the Google Maps. On running the (see below) sql i get nothing. I hardcoded the values. I just want to mention that i'm relatively new to PostGIS; what am i doing wrong?

SELECT * FROM cg_dxf_shapes WHERE ST_Intersects( gis_stereo_shape, ST_Transform( ST_Envelope( ST_GeomFromText('LINESTRING(47.73964811979098 26.09410725402836, 47.75263376633051 26.124834640502968)',4326) ), 31700 ) ) = TRUE I've tried different variations, but with no result; even when using the 4326 SRID on both geometries.

Thanks.

EDIT This is another variation without conversion.

SELECT * FROM cg_dxf_shapes WHERE ST_Intersects( gis_geographic_shape, ST_Envelope( ST_GeomFromText('LINESTRING(47.73964811979098 26.09410725402836, 47.75263376633051 26.124834640502968)',4326) ) )

أكثر...
 
أعلى