<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0">
	<channel>
		<title><![CDATA[Latest posts for the topic "Nearby places and features from database"]]></title>
		<link>http://forum.geonames.org/gforum/posts/list/4.page</link>
		<description><![CDATA[Latest messages posted in the topic "Nearby places and features from database"]]></description>
		<generator>JForum - http://www.jforum.net</generator>
			<item>
				<title>Nearby places and features from database</title>
				<description><![CDATA[ I'm building an application that will allow users to enter a latitude/longitude pair and get the nearest placename. 

Obviously, this can easily be done by a lookup to the geonames webservice, but, where possible, I prefer to use local data in my own database rather than a webservice for two reasons: Firstly, I prefer not to have to be dependent on an external site for the functionality of my own, and secondly, however generous the operators of the webservice are, I'm still aware of the fact that every lookup I make consumes their resources - and I don't want to have to worry about either hurting them (due to imposing too much load) or hurting me (because my app stops working when I run out of free lookups).

However, doing it via MySQL is painfully slow - up to half a minute to find the nearest location to an arbitrary lat/lon pair in the full geonames table using a standard "great circle" calculation. But it obviously can be done quickly, because the webservice manages it.

So, before I give up and use the webservice anyway, is there anything obvious that I'm missing here that would enable me to replicate the speed at which the webservice returns nearby location data?

Mark]]></description>
				<guid isPermaLink="true">http://forum.geonames.org/gforum/posts/list/971.page#4321</guid>
				<link>http://forum.geonames.org/gforum/posts/list/971.page#4321</link>
				<pubDate><![CDATA[Sat, 12 Jul 2008 20:56:51]]> GMT</pubDate>
				<author><![CDATA[ marksg]]></author>
			</item>
	</channel>
</rss>