<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0">
	<channel>
		<title><![CDATA[Latest posts for the topic "Query used for searching string with city and state name"]]></title>
		<link>http://forum.geonames.org/gforum/posts/list/4.page</link>
		<description><![CDATA[Latest messages posted in the topic "Query used for searching string with city and state name"]]></description>
		<generator>JForum - http://www.jforum.net</generator>
			<item>
				<title>Query used for searching string with city and state name</title>
				<description><![CDATA[ Hi Everyone,

I imported the mysql dump provided by the site. Thanks a bunch for making it easy. 

I am trying to implement a function that will take a input given by the user and return the lat, long for that string.

The string might be "San Francisco, ca" or "San Francisco CA".

What is the best way to write a query on the geoname table to search for the above strings. I see that the name column only includes "San Francisco" while the admin1 column contains "CA" string. 

Any suggestions are welcome. 
Thanks in advance,
Sushil
]]></description>
				<guid isPermaLink="true">http://forum.geonames.org/gforum/posts/list/1649.page#6814</guid>
				<link>http://forum.geonames.org/gforum/posts/list/1649.page#6814</link>
				<pubDate><![CDATA[Mon, 7 Dec 2009 06:34:56]]> GMT</pubDate>
				<author><![CDATA[ sushil]]></author>
			</item>
			<item>
				<title>Re:Query used for searching string with city and state name</title>
				<description><![CDATA[ If this is the only format you allow and if it is exactly city name and state code then you can parse  the query string and query the database on the placename and the admin1code columns.

For user input this is normally not flexible enough and you will have to implement a full text search or use the GeoNames search web service.

Best

Marc]]></description>
				<guid isPermaLink="true">http://forum.geonames.org/gforum/posts/list/1649.page#6819</guid>
				<link>http://forum.geonames.org/gforum/posts/list/1649.page#6819</link>
				<pubDate><![CDATA[Tue, 8 Dec 2009 07:53:52]]> GMT</pubDate>
				<author><![CDATA[ marc]]></author>
			</item>
			<item>
				<title>Re:Query used for searching string with city and state name</title>
				<description><![CDATA[ Thanks for the info Marc. Implementing a full text search is painful and I will pretty much hit the search webservice limit very soon. I guess i will have to search for some other alternative.

Thanks anyways.]]></description>
				<guid isPermaLink="true">http://forum.geonames.org/gforum/posts/list/1649.page#6821</guid>
				<link>http://forum.geonames.org/gforum/posts/list/1649.page#6821</link>
				<pubDate><![CDATA[Tue, 8 Dec 2009 08:52:09]]> GMT</pubDate>
				<author><![CDATA[ sushil]]></author>
			</item>
	</channel>
</rss>