Hi,
   While modelling unowned many-to-many relationship as mentioned in
http://code.google.com/appengine/docs/java/datastore/relationships.html

adding or removing a relationship requires loading of all keys of the
other object.

public void addFavoriteFood(Food food) {
    favoriteFoods.add(food.getKey());
    food.getFoodFans().add(getKey()); ///loads all the foodFans in the
Food object
}

public void removeFavoriteFood(Food food) {
    favoriteFoods.remove(food.getKey());
    food.getFoodFans().remove(getKey()); ///loads all the foodFans in
the Food object
}


Is there a way to avoid this?

-- 
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 google-appengine-j...@googlegroups.com.
To unsubscribe from this group, send email to 
google-appengine-java+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-appengine-java?hl=en.

Reply via email to