> You're right about 2): more efficient because only key is accessed: i/ > o limited to index rather than index + table when you fetch the entire > entity. So more disk i/o and more bytes to transfer between the > datastore server and the server of your jvm.
OK > About 3): 2 important points come to mind: (a) using ancestor key > means that you know how your entities are grouped in the datastore for > transactional purposes: i.e you need to know the parent for each > entity key you want to check But I also need to know the parent key for '2)' way. What is the difference? >and (b) according to this grouping, get > on 1 ancestor key may return more than 1 child entity and then you may > lose the performance optimization that you are looking for. When I call setAncestor() I pass the complete key: all parents keys + the entity key. So query can't return more than 1 entity. So I don't see the benefit from '2)' way accoring to your reply. -- You received this message because you are subscribed to the Google Groups "Google App Engine for Java" 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-java?hl=en.
