[OSM-talk] all POIs within a specific radius
Frederik Ramm
frederik at remote.org
Mon Aug 8 09:40:27 BST 2011
Hi,
On 08/08/11 07:51, kenneth gonsalves wrote:
> I manufactured this SQL, but it selects *every* locality on the map:
>
> select name from planet_osm_point where place = 'locality' and
> ST_DWithin(way,(select way from planet_osm_point where name
> like 'Bangalore%' limit 1),300) order by name;
Is it possible that your database is not in Mercator projection but in
latitude/longitude (-l option on osm2pgsql)? In that case you would be
selecting everything within 300 degrees of Bangalore, and you'd have to
try a distance of about .0003 for something roughly like 300 metres.
Bye
Frederik
More information about the talk
mailing list