db-torque-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Tobias Hilka" <thi...@vps.de>
Subject AW: Logging of sql statements of a single peer class
Date Tue, 11 Dec 2007 11:21:28 GMT
Hi Thomas,

thank you for your help.

We will go with the straightforward way to log all sql statements and filter
the file afterwards.


-----Urspr√ľngliche Nachricht-----
Von: Thomas Fischer [mailto:fischer@seitenbau.net] 
Gesendet: Dienstag, 11. Dezember 2007 12:09
An: Apache Torque Developers List
Betreff: AW: Logging of sql statements of a single peer class

> But there is a problem with this solution. The sql statements are
> somewhere inside torque, not in the peer classes. If I have a criteria in
> the peer classes, I can get most of the information from this criteria.
> if I do a BaseRecord.save(), which is actually outside of the peer class,
> but in the same layer, I don't have the information how the sql
> looks like.

Statements for queries are generated inside Torque, and you can log them
via Criteria.toString after the adjustments to criteria are made. The
statements for inserts are generated inside village, and there is currently
no good way to get them. The options are:
- patch village
- use a logging jdbc driver (P6Spy)
But neither fulfills the requirements of logging the statements for just a
single table. Sorry, this is the best I can think of.


To unsubscribe, e-mail: torque-dev-unsubscribe@db.apache.org
For additional commands, e-mail: torque-dev-help@db.apache.org

View raw message