Answer the question
In order to leave comments, you need to log in
What is the difference between using Spring JDBC Template and Hibernate ORM HQL?
Hello ! I am learning Spring and am now trying to fill in some knowledge gaps.
What is the difference between using Spring JDBC Template and using Hibernate ORM HQL?
-As far as I understand, the abstraction level of Hibernate ORM HQL queries is higher than that of Spring JDBC Template. BUT !
As I see it, using the SessionFactory, Session methods that need to be opened, closed, in my opinion, only slightly makes the code larger and no more, the code on the Spring JDBC Template seems even smaller.
So what is the difference then and the point of using Hibernate in this case?
________________________________________________________________________________________________________
Spring JDBC Template code (short):
https://github.com/doIT-courses/Java-Web/blob/mast...
Hibernate ORM HQL code (short):
https://github.com/doIT-courses/Java-Web/blob/mast. ..
Answer the question
In order to leave comments, you need to log in
In general, these are different things.
Hibernate is an ORM framework with a lot to offer.
And Spring JDBC Template is syntactic sugar over JDBC.
IMHO, consider Hibernate only within the framework of Spring Data Jpa.
Because a very handy thing that makes working with Hibernate a lot easier.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question