jdo - FetchPlan does not work -
i'm new subject pardon me if missing or misunderstanding something.
i'm using jdo 3.1rc1 , datanucleus 3.2.7.
this data class (kept short as possible):
@persistencecapable @fetchgroup(name="dailyavailablemenuitemsgroup", members={@persistent(name="_id"), @persistent(name="daily"), @persistent(name="available"), @persistent(name="available_mode")}) public class menuitem { ... // many @persistent fields here, string or boolean type }
and here code attempted retrieve partial fields here
pm.getfetchplan().cleargroups(); pm.getfetchplan().addgroup("dailyavailablemenuitemsgroup"); query q = pm.newquery(menuitem.class); @suppresswarnings("unchecked") list<menuitem> menuitems = (list<menuitem>) q.execute();
however when looping through results, appears fields have values, instead of null have expected. tried dynamic way of doing thinking issue annotations no avail. idea have gone wrong?
Comments
Post a Comment