> > For example, I may have run "SELECT * from WIDGETS" and
> > gotten back a collection of entities which may or may not all share
> > the same model.
>
> The datastore does not support SELECTing from different entity 
> kinds:http://code.google.com/appengine/docs/datastore/gqlreference.html
>
> You can use an Expando model and call dynamic_properties() to iterate
> over the props:
>
> for prop in entity.dynamic_properties():
>     value = getattr(entity, prop)

On a second thought, you probably want to query from one kind at a
time, but vary the model name in your GQL query.

If that's the case, David's suggestion above should work. Just be
careful, Model.properties() returns a dictionary of Property
subclasses, not the actual values. You will have to get the values
with getattr() passing your entity and the property name.
--~--~---------~--~----~------------~-------~--~----~
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