Granny's Programming Pearls
"inside of every large program is a small program struggling to get out"
JavaRanch.com/granny.jsp
The moose likes Object Relational Mapping and the fly likes JPA query optimization Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Databases » Object Relational Mapping
Bookmark "JPA query optimization" Watch "JPA query optimization" New topic
Author

JPA query optimization

debraj mallick
Ranch Hand

Joined: Mar 08, 2011
Posts: 188

hi all,

i have a table "Semiproduct" and have the id of the "Semiproduct", in tables "SemiproductSales" and "SupplyArea" as foreign key, say for example

entities "SemiproductSales" and "SupplyArea" have multiple "Semiproduct". Now when query on SemiproductSales

multiple queries are generated which reduces the performance, if the query result set is 5000 then 5001 queries are generated. what should i do?
I am using Hibernate implementation of JPA,
any help would be appreciated.
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
 
subject: JPA query optimization
 
Similar Threads
How to Write Left Outer Join
JPA [Collections]
Saving database records problem
JPA strange error.
Mysql auto generated PK used for another table and JPA