Think on having a dbmodel to store that locations, like the following:

# model definition
class Poi(db.Model):
  name = db.StringProperty()
  lat = db.FloatProperty()
  lon = db.FloatProperty()
  geohash = db.StringProperty()

Geohash is a string built from longitude and latitude values that can
be used as a geographical index, and to perform proximity queries, and
sort of bbox queries. The following is a sample bbox query based on
geohash properties:

# query code
southwest = str(Geohash((minlon,minlat)))
northeast = str(Geohash((maxlon,maxlat)))
q = db.GqlQuery("SELECT * FROM Poi " +
                           "WHERE geohash > :1 AND geohash <= :2 " +
                           "ORDER BY geohash DESC",
                           southwest, northeast)

That can get more complicated if your bbox crosses the equator or the
-180ยบ meridian, even in other cases as I heard, and you also might
have to filter false positives -data returned by the query that falls
out the bbox-, but it's a beginning.

I describe my approach here:
http://public.grupoinnovant.com/blog/?p=23

Other interesting references:
http://labs.metacarta.com/blog/27.entry/
http://mappinghacks.com/code/geohash.py.txt
http://en.wikipedia.org/wiki/Geohash
http://catherinedevlin.blogspot.com/2008/09/bigtable-blues.html

On 18 abr, 23:06, perinouk <[email protected]> wrote:
> Hi,
>
> I have an urgent need to present about 10,000 locations on a google
> map. I have geo codes (latitude and longitude) for the locations but I
> need to understand how I can quickly create a map like this and if I
> need to host this locally or google allow me to host it on their
> servers. Also, I would like access control to the map.
>
> Thnks for all your help!
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/google-appengine?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to