Skip to main content

Notice: This Wiki is now read only and edits are no longer possible. Please see: https://gitlab.eclipse.org/eclipsefdn/helpdesk/-/wikis/Wiki-shutdown-plan for the plan.

Jump to: navigation, search

Difference between revisions of "EclipseLink/Examples/JPA/GraphLoading"

(New page: <div style="border:1px solid #999999;background-color:#ffffff;align:center"> <table border="0" cellpadding="5" align="center"><tr><td width="20">image:Catnicon.gif</td><td>This page is...)
 
(How to Optimize Object Graph Loading with JPA)
Line 6: Line 6:
  
 
A common problem developers face when using object-relational solutions is how to optimize the loading of a graph or related objects. By default a query for the root object type and default navigation through the graph can result in a N+1 SQL performance problem. This how-to highlights EclipseLink JPA's available solutions.
 
A common problem developers face when using object-relational solutions is how to optimize the loading of a graph or related objects. By default a query for the root object type and default navigation through the graph can result in a N+1 SQL performance problem. This how-to highlights EclipseLink JPA's available solutions.
 +
 +
== Example Model ==
 +
 +
== Querying without Optimizations ==
 +
 +
== JPQL JOIN FETCH ==
 +
 +
== EclipseLink Hints ==
 +
 +
EclipseLink provides additional support for joining and batch reading using query hints.
 +
 +
=== JOIN FETCH Hint ===
 +
 +
=== BATCH Hint ===

Revision as of 16:34, 3 April 2008

Catnicon.gifThis page is under construction.

How to Optimize Object Graph Loading with JPA

A common problem developers face when using object-relational solutions is how to optimize the loading of a graph or related objects. By default a query for the root object type and default navigation through the graph can result in a N+1 SQL performance problem. This how-to highlights EclipseLink JPA's available solutions.

Example Model

Querying without Optimizations

JPQL JOIN FETCH

EclipseLink Hints

EclipseLink provides additional support for joining and batch reading using query hints.

JOIN FETCH Hint

BATCH Hint

Back to the top