If your key name was the based off of datetime.utcnow().isoformat() you
could always get the last entity created by doing a query like this:
last_created = model.all().filter('__key__ <', db.Key.from_path('model',
datetime.utcnow().isoformat())).get()
and you could get the next newest by finding the entity with a __key__ <
last_created.key().
But beware of monotonically increasing values:
http://ikaisays.com/2011/01/25/app-engine-datastore-tip-monotonically-increasing-values-are-bad/
--
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.