Here is why comparing key does not work:

import models

pk=models.Page(key_name='_blocks')

q=models.Page.gql("WHERE __key__ >= :1", pk.key())

[p.key().name() for p in q]

[u'_blocks--callout', u'_blocks--callout-contact', u'_blocks--footer-center', 
u'_blocks--teaser', u'_slides--home--1', u'about', u'collections', u'default', 
u'faq', u'shipping']



In my implementation key name is a "slug" for page. I want only those pages 
wich slug begins with '_blocks'. Is it possible quering by key name?

I thought about [p for p in models.Page.all() if p.key().name() >= 
'_blocks'], but I doubt it has good perfomance on large set of entities.

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To view this discussion on the web visit 
https://groups.google.com/d/msg/google-appengine/-/Z8h6AQSoQw4J.
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