-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 1 post ] 
Author Message
 Post subject: How to log Hibernate SQL for a specific Java package
PostPosted: Sat Sep 13, 2014 4:52 pm 
Newbie

Joined: Fri Sep 12, 2014 7:48 pm
Posts: 1
Hibernate allows SQL to be printed in the logs by using log4j.properties as

Code:
log4j.category.org.hibernate.SQL = ALL


However this prints Hibernate SQL logs for the entire application. Is there a way to limit logging to a specific Java package? e.g. I may only want SQL to be printed for the Java package com.example.app.dao.complex, and not for any other packages. How do I accomplish this? Thanks in advance.


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 1 post ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.