http://code.google.com/appengine/docs/java/datastore/queriesandindexes.html#Introducing_Queries
See "Query Filters". Should answer your how-to question. In the backend it actually does two separate queries, but in parallel (then does any merging/union-ing based on your entire query after retrieving the results). There are some google tech talks on how the datastore works which should give you a really good idea why it is done this way. On Sun, Sep 5, 2010 at 10:34 PM, killer barney <ajcha...@gmail.com> wrote: > This is something I never figured out how to do. How do you > supplement an OR statement in datastore? > > So let's say I have a user who sells Dogs and Cats. How do I get a > list of all of the dogs and cats that a user sells? I thought of 2 > ways, query both tables and combine the results in the backend or > create an additional generic table Animals that tabulates all of the > selling action into a list and search the Animals entries for that > user. > > I created this scenario just so you can have an idea of what I am > looking for, but in reality, my "cats" table may consist of hundreds > of users. I'm not sure if creating a combined list property of Dog > and Cat users is the way to go. And doing two queries just doesn't > seem right either. Is there a better way to do this? > > -- > 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-appeng...@googlegroups.com. > To unsubscribe from this group, send email to > google-appengine+unsubscr...@googlegroups.com<google-appengine%2bunsubscr...@googlegroups.com> > . > For more options, visit this group at > http://groups.google.com/group/google-appengine?hl=en. > > -- 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-appeng...@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.