On Tue, Jul 26, 2011 at 6:02 AM, M. Walter marc.wal...@sbb.ch wrote:
I did the following:
final OpenJPAQuery ojpaQuery =
OpenJPAPersistence.cast(em.createNamedQuery(
StammdatenQueryNames.FIND_ALL_BP.name()));
ojpaQuery.getFetchPlan().removeFetchGroup(FetchGroup.NAME_DEFAULT);
:
http://openjpa.208410.n2.nabble.com/Best-practice-Using-fetch-groups-or-a-simple-DTO-tp6598057p6625117.html
Sent from the OpenJPA Users mailing list archive at Nabble.com.
(FetchGroup.NAME_DEFAULT);
ojpaQuery.getFetchPlan().addFetchGroup(short);
final ListBp result = ojpaQuery.getResultList();
All fields and all relationships are loaded. Another idea?
--
View this message in context:
http://openjpa.208410.n2.nabble.com/Best-practice-Using-fetch-groups-or-a-simple-DTO
);
do
ojpaQuery.getFetchPlan().clearFetchGroups();
-
Pinaki Poddar
Chair, Apache OpenJPA Project
--
View this message in context:
http://openjpa.208410.n2.nabble.com/Best-practice-Using-fetch-groups-or-a-simple-DTO-tp6598057p6622661.html
Sent from the OpenJPA Users mailing list archive
.n2.nabble.com/Best-practice-Using-fetch-groups-or-a-simple-DTO-tp6598057p6622771.html
Sent from the OpenJPA Users mailing list archive at Nabble.com.
plan has not regressed.
If you can supply a JUnit test with assertions, that will help further
analysis.
-
Pinaki Poddar
Chair, Apache OpenJPA Project
--
View this message in context:
http://openjpa.208410.n2.nabble.com/Best-practice-Using-fetch-groups-or-a-simple-DTO-tp6598057p6622886
://openjpa.208410.n2.nabble.com/Best-practice-Using-fetch-groups-or-a-simple-DTO-tp6598057p6617686.html
Sent from the OpenJPA Users mailing list archive at Nabble.com.
Try removing the default fetchgroup?
Thanks,
Rick
On Mon, Jul 25, 2011 at 4:49 AM, M. Walter marc.wal...@sbb.ch wrote:
It does not work as described in the documentation. Or am I missing
something?
Here is my entity:
@Entity
@Table(name = BP)
@FetchGroup(name = short, attributes = {
relations? Are they
initialized with null if they are not defined in my custom FetchGroup?
I'm using OpenJPA 1.2.3 so please keep that in mind when answering. Thank
you!
--
View this message in context:
http://openjpa.208410.n2.nabble.com/Best-practice-Using-fetch-groups-or-a-simple-DTO-tp6598057p6601589
?
Thanks for your input!
--
View this message in context:
http://openjpa.208410.n2.nabble.com/Best-practice-Using-fetch-groups-or-a-simple-DTO-tp6598057p6598057.html
Sent from the OpenJPA Users mailing list archive at Nabble.com.
10 matches
Mail list logo