By Alvin Alexander. Last updated: June 4, 2016
Java Hibernate debug faq: How can I see the SQL that is actually being run/executed when I'm using Hibernate?
To debug Hibernate output, just configure this parameter in your hibernate.properties
file:
hibernate.show_sql=true
This Hibernate configuration parameter will cause Hibernate to show the actual SQL that is being generated/used when your queries are run. Of course it can be a little verbose, but hopefully it will also give you all the SQL you need to troubleshoot your problem.