Clearly i'm just as lost now as before....
On Sep 14, 7:54 pm, bysse <[email protected]> wrote:
> Okej, i've learned a bit more since i've posted these messages. I
> didn't quite understand (still don't probably) fetchgroups and detach
> enough.
>
> Anyway, the problem i had with could be avoided by defining fetch
> groups for fields that will be stored in different "tables".
> If i have a declaration like this:
>
> @PersistenceCapable(identityType = IdentityType.APPLICATION,
> detachable = "true")
> @FetchGroup(name = "ItemValues", members = { @Persistent(name =
> "values") })
> public class Item implements Serializable {
> //...
> �...@persistent
> private Set<Value> values;
> // ...
>
> }
>
> And i want to get an entity from the datastore including the field
> values. I have to the FetchGroup "ItemValues" to the FetchPlan:
>
> pm.setDetachAllOnCommit(true);
> pm.getFetchPlan().addGroup("ItemValues");
> Query query = pm.newQuery(Item.class);
> ...
>
> This way all the basic fields and the field values will be filled when
> the query returns.
>
> On Aug 14, 6:23 pm, bysse <[email protected]> wrote:
>
> > Ah true, i had a call to pm.setDetachAllOnCommit(true) that i didn't
> > see.
> > It's a bit disturbing that i can't pinpoint the error, i'll continue
> > on this thread if it pops up again.
>
> > thanks a lot for your answers
>
> > On Aug 14, 6:03 pm, datanucleus <[email protected]> wrote:
>
>
--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---