Win a copy of Java 9 Revealed this week in the Features new in Java 9 forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Question to Vlad about ORM performance  RSS feed

 
Trist Post
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have two questions:

Are there any ORM tools that whete it makes sense make use of stored procedures?

Are SQL produced by the best ORM solutions today generally as efficent (or more so) as that produced by the average developer?
 
Vlad Mihalcea
Author
Ranch Hand
Posts: 33
6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
ORMs are about OLTP, while stored procedures are more for OLAP.
In my experience, the best support for stored procedures is what jOOQ offers.

Whenever a tool auto-generates statements for you, you need to validate that the statements are the right ones.
But then, the auto-generated statements Hibernate offer you the following benefits:

- you can enable JDBC batch updates with just a configuration.
- once you add/remove/rename a column, all the insert/update/delete statements are going to reflect that change
- you also get support for optimistic locking
- you can paginate even native queries not just JPQL queries
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!