Just to add to objectuser, you definitely need to use entity groups to retrieve all entity types within a transaction if you use the model you're both describing.
You might want to consider a change in your model though to move the most updated fields in User to a new and different entity, freeing you from needing to retrieve Track and User for those updates. >From your description that new entity is found with name fields that are the same fields as in the User and Track entities. This is 2nd normal form in terms of a database model... On Jun 25, 9:33 am, objectuser <kevin.k.le...@gmail.com> wrote: > As long as both the user and tracks are in the same entity group, you > can do just that. > > Whether that's a good idea or not depends on how those users and > tracks will be used. If only one user is going to be messing with the > tracks, then you should be fine. If many users need to update those > tracks, then you will have a lot of contention on that entity group. > This is all because only one transaction can update an entity group at > a time. > > On Jun 24, 2:47 am, Martin Newstead <skankmar...@hotmail.com> wrote: > > > > > > > > > I would like some help and advice on how to model my entities using > > JDO on GAE. My problem is this, I have a bunch of Users and each User > > may create zero or more Tracks. Users may exist without a Track but > > Tracks may not exist without a User who created them. Other attributes > > on the User and the Track may updated. I would like to be able to > > query the Tracks and retrieve some attributes from the User who > > created the Track. The attributes from the User may get updated. In > > SQL this would be > > > select u.displayName, t.trackName from User u, Track t, where > > t.userId=u.userId > > > I have some ideas and have tried various things but this isn't a post > > on why doesn't something work, more of what is the best practice to > > solve this problem. > > > thanks <M -- 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-java@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.