I think he's already got the data he want, just needs to extract the
individual fields from the CSV data.
The split function will be a simple way to achieve this.
e.g.
strArray = strInputLine.split(',')
strPlace = strArray[0]
strXcoord = strArray[1]
etc.
HTH
Phil
On 6 April 2011 18:13, Barry
Python has a CSV reader that does things like escape characters:
http://docs.python.org/library/csv.html
Ikai Lan
Developer Programs Engineer, Google App Engine
Blog: http://googleappengine.blogspot.com
Twitter: http://twitter.com/app_engine
Reddit: http://www.reddit.com/r/appengine
On Thu,
Thanks Ikai, but the problem is to obtain the city and the country from the
coordinates.
Max
2011/4/7 Ikai Lan (Google) ika...@google.com
Python has a CSV reader that does things like escape characters:
http://docs.python.org/library/csv.html
Ikai Lan
Developer Programs Engineer, Google
As long as you're only interested in *displaying* the city, and not querying
on it, one sneaky solution would be to do the lookup in Javascript, using
the clients processing power and not your App, using an API like SimpleGeo's
or Google's reverse geocoder:
Max,
There is a nice python library called xlwt, I'm sure you can find it
via Google. It lets you read and write Microsoft Excel files.
Cheers
On Apr 6, 9:07 am, Massimiliano massimiliano.pietr...@gmail.com
wrote:
Hi,
can someone help me? A big problem for me, I hope easy for you. I have a
I'm not afraid how to import the CSV. I don't know how to manage the data to
obtain the city and country with the coordinates!
2011/4/6 JH jamesthop...@gmail.com
Max,
There is a nice python library called xlwt, I'm sure you can find it
via Google. It lets you read and write Microsoft Excel
You need to use a geocoder (well technically a reverse geocoder). That will
most probably be connecting to an external webservice, such as geonames, or
the one in the Google Maps API.
(note if you use the Google Maps API one, you must use teh data to shown a
Google Map on your site)
It could be