I need to log all the queries to an Oracle database in my project to a log file.
What would be a good solution to achieve this? Some sample usage would be appreciated.
I have looked at SLF4J with jdbcdslog, but I'm not sure how I can log to a file with it. Moreover, I would need to "filter" some of the logs (because I don't need to know when some getxxxx
method get's invoked)
Preferably, I'd prefer to use java.util.logging
but it is not a requirement.
Thanks.
** UPDATE **
I found this Oracle article, however it does not really tell how to programatically do the same thing.