This content has been marked as final.
Show 3 replies
-
1. Re: How to print SQL values in debug Log
ejb3workshop Oct 11, 2007 8:41 AM (in response to terryb)You can use the following properties :
hibernate.show_sql
hibernate.format_sql
hibernate.use_sql_comments
Take a look at the hiberante documentation for more details:
http://www.hibernate.org/hib_docs/reference/en/html/session-configuration.html -
2. Re: How to print SQL values in debug Log
terryb Oct 11, 2007 9:31 PM (in response to terryb)Thank you, it looks better now.
Also to see the actualy data being written to the database, I figured it is hibernate.type entry needs to be set in log4J.properties file in the classes folder. Though I haven't tried it yet. -
3. Re: How to print SQL values in debug Log
alrubinger Oct 11, 2007 11:16 PM (in response to terryb)Also, you can enable in Log4J settings:
<category name="org.hibernate.tool.hbm2ddl.SchemaExport" additivity="false"> <priority value="DEBUG" /> </category> <category name="org.hibernate.tool.hbm2ddl.SchemaUpdate" additivity="false"> <priority value="DEBUG" /> </category> <category name="org.hibernate.SQL" additivity="false"> <priority value="DEBUG" /> </category>
S,
ALR