[odb-users] how to see the sql executing?

Boris Kolpackov boris at codesynthesis.com
Fri Aug 26 14:07:13 EDT 2011


Hi,

spiritonly at gmail.com writes:

> I want to see the sql executing like hibernate

ODB doesn't support this. For performance reasons we use prepared
statements throughout and pass data in binary form. As a result,
it will be very difficult to print anything meaningful. The best
we could do is to print a statement without the data, so you
would see something like INSERT INTO Foo VALUES(?, ?, ?) -- not 
very useful.

The better way to achieve this would be to use the database server
logs. Most (all?) database servers provide the ability to see the
SQL statements as they are being executed. Check your database
server documentation for more information on how to do this.

Boris



More information about the odb-users mailing list