You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This selects all the requests within 1000 meters around the given point
SELECT *
FROM carryon."HELP_REQUEST"
WHERE ST_DWithin("GEOM", ST_MakePoint(-71.060312, 48.432044)::geography, 1000);
This selects all the requests within 1000 meters around the given point ordered by distance
SELECT "ID", "TITLE", ST_Distance("GEOM", ref_geom) AS distance
FROM carryon."HELP_REQUEST"
CROSS JOIN (SELECT ST_MakePoint(-71.050312, 48.432044)::geography AS ref_geom) AS r
WHERE ST_DWithin("GEOM", ref_geom, 1000)
ORDER BY ST_Distance("GEOM", ref_geom);