Win a copy of The Business Blockchain this week in the Cloud forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Question to Vlad about ORM performance

 
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: 32
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
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic