问题
I have several records in my database with the same parent. How can I get all of them by parent?
回答1:
OK, looks like the following code works:
items = ITEM.gql('WHERE ANCESTOR IS :parent', parent=parent_key).fetch(5)
来源:https://stackoverflow.com/questions/7868333/how-to-get-all-records-from-gae-datastore-with-particular-parent