How to Log SQL on JBoss - betweenGo

<appender name="CONSOLE" class="org.apache.log4j.ConsoleAppender">
<errorHandler class="org.jboss.logging.util.OnlyOnceErrorHandler"/>
<param name="Target" value="System.out"/>
<!-- param name="Threshold" value="INFO"/ -->
<param name="Threshold" value="DEBUG"/>

<layout class="org.apache.log4j.PatternLayout">
<!-- The default pattern: Date Priority [Category] Message\n -->
<param name="ConversionPattern" value="%d{ABSOLUTE} %-5p [%c{1}] %m%n"/>
</layout>

<!-- Hajime's change -->
<category name="org.jboss.ejb.plugins.cmp.jdbc">
<priority value="DEBUG"/>
</category>

<category name="org.hibernate.SQL">
<priority value="DEBUG"/>
</category>
</appender>