<br><br><div class="gmail_quote">2009/9/10 Sajjad Anwar <span dir="ltr"><<a href="mailto:sajjadkm@gmail.com">sajjadkm@gmail.com</a>></span><br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
Hello.<br>Im new to this list. Perhaps my first email.<br><br>Im trying to write a geocoding application for my city (Calicut, Kerala, India). Currently Im updating the database using JOSM. I understood that, I need to query the database with the string the user provider through my application. What is the way for that? I also understood that, as Im in India, we can reduce the false results by extrating the smaller subset of India Database. How could that be done? Somebody in the channel gave me an XML datasheet of India. How do I use that into a database in my server and application? I plan to code in Python. <br>
Please help. Thank you.<br clear="all"></blockquote></div><font class="Apple-style-span" color="#888888"><br></font><div><font class="Apple-style-span" color="#888888">The first thing that you want is to get an extract of the database. You could download the entire planet or you can go to either Cloudmade or Geofabrik sites to have that database. <a href="http://planet.openstreetmap.org">http://planet.openstreetmap.org</a></font></div>
<div><font class="Apple-style-span" color="#888888">Since you are mostly concerned about your city, grab the smallest extract of India and then use Osmosis to cut this extract with a bounding containing your town. <a href="http://wiki.openstreetmap.org/wiki/Osmosis">http://wiki.openstreetmap.org/wiki/Osmosis</a></font></div>
<div><font class="Apple-style-span" color="#888888">There are two tools to import OSM data into a postgres database: Osmosis and osm2pgsql. They have 2 different schemas. Osmosis is quite complete but more difficult to work this, while osm2pgsql is done for Mapnik rendering.</font></div>
<div><font class="Apple-style-span" color="#888888">It is likely that if you are building a geocoding application from scratch, that you will need to extract the data from one of those schemas. Else, you can ask around if you could use one of the existing engine for your town.</font></div>
<div><font class="Apple-style-span" color="#888888"><br></font></div><div><font class="Apple-style-span" color="#888888">Emilie Laffray</font></div>