Hi Matt,
Matt Raible wrote:
On 12/11/07, Rob Hills <[EMAIL PROTECTED]> wrote:
Hi Matt,
Matt Raible wrote:
Finally, it'd be really nice to be able to turn this on and off via the
POM the way you can for hibernate.show_sql.
How is this possible from the POM? There's nothing we're doing special
that I know of
Hmmm, OK. I have the following in the "properties" element of my "dev"
profile in my profiles.xml:
<hibernate.show_sql>true</hibernate.show_sql>
<hibernate.use_sql_comments>true</hibernate.use_sql_comments>
Can't say now where I got them from, or even if they work. FWIW,
googling "hibernate.show_sql" turns up a lot of hits, including lots of
references to its use in pom properties.
For this to work, you probably have placeholders for these properties
in jdbc.properties. Can you check and see? This is not standard in
AppFuse, but there's probably not much harm in adding it.
You're absolutely right of course. I didn't and when I disabled SQL
logging in the log4j.xml file, there was no sql logging in my output. I
then looked at the properties for the profile I'm using ATM (postgresql)
and it wasn't using any hibernate.show_sql property so that's one reason
to expect it not to work.
I've tried "hard-coding" the hibernate.show_sql property in my posgresql
profile in my pom without making any other changes, but that didn't make
any difference.
Unfortunately, my understanding of the interaction between maven and
hibernate and logging entries is limited so my only tool is
trial-and-error and I have a couple of deadlines approaching quickly so
I don't have the time right now to play with it. I'll experiment in the
background and if I turn up anything that works, I'll report back.
Cheers,
Rob Hills
Waikiki, Western Australia
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]