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

Hibernate session.load() method doubt  RSS feed

 
Vivek Raj
Ranch Hand
Posts: 33
Chrome Eclipse IDE Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi All,
I am new to Hibernate and was practicing a simple example to save() and load() the data.

I have set <property name = "show_sql">true</property>, to see the queries generated by Hibernate.

When saving the data using session.save() I can see the insert queries, but I cannot see any queries when executing the session.load(). For session.load() I can see the select queries only when I try to actually print the data using SOP.

I have created my class using main for testing the load():


 
Nam Ha Minh
Ranch Hand
Posts: 515
Eclipse IDE Firefox Browser Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
What does the Javadoc of Session.load() say about?
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!