Hi Khai,

Due to the way entities are indexed, there's no way to query directly
for entities with empty lists. Your best option is to add a
BooleanProperty that you set to True whenever the ListProperty is
empty, and query on that.

-Nick Johnson

On Thu, Jun 25, 2009 at 11:44 PM, Khai<khaitd...@gmail.com> wrote:
>
> I have a model:
>
> class BlogEntry(db.Model):
>    content = db.TextProperty()
>    tags = db.StringListProperty()
>
> To fetch entries that had been tagged with 'Math', I would write a
> GQL:
>
> BlogEntry.gql("WHERE tags = :tag", tag = "Math")
>
> How can I fetch entries that had not been tagged?
> >
>



-- 
Nick Johnson, App Engine Developer Programs Engineer
Google Ireland Ltd. :: Registered in Dublin, Ireland, Registration
Number: 368047

--~--~---------~--~----~------------~-------~--~----~
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 
google-appengine+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/google-appengine?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to