Win a copy of The Little Book of Impediments (e-book only) this week in the Agile and Other Processes forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Is there any way to print the actual query executed by the hibernate?

 
Sat Nar
Ranch Hand
Posts: 83
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi All,
I want to print the actual query executed by the hibernate. Is there any way for it? Thanks in advance.
 
Paul Sturrock
Bartender
Posts: 10336
Eclipse IDE Hibernate Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Yes. The configuration property hibernate.show_sql (and the useful hibernate.format_sql) will log the SQL used. You will need to enable debug logging for org.hibernate.type to see the values bound if you are using binding.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic