There's the problem of "show everything close to a geopt". I came
around it by iterating a 2nd time after the query and saving only
nearby entities to a new list as at most one property per query can
have inequality filter and geohash isn't usable. So we can filter and
find everything in a radius or even exactly within by geopts defined
city limits. It would however be preferred to do this without the 2nd
iteration.
L=[]
things = Thing.all().filter("modified >", twomonthsback).order("-
modified)
            if self.request.get('lat'):
                for thing in things:
                    if thing.geopt:
                        if thing.geopt.lat < float(self.request.get
('lat')):
                            L.append(thing)
Despite the extra iteration this way seems better for the user than
geohash as there are no borders, Now close but different geopt inputs
will output more similar lists than with the geohash where the geohash
border could be e.g. in the middle of a locality. Please let me know
your comments.
best regards,
Niklas
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To post to this group, send email to google-appengine@googlegroups.com
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