SQL batch file logger Private: (?) No Appender that writes a trace of JDBC activity into an SQL
batch file that can be later "replayed" using a generic SQL client.
modify the spy.properties file to make p6spy use this appender by setting
appender=com.p6spy.engine.spy.appender.BatchFileLogger.
Here's how it works for me: logfile = spy.sql The appender writes the text of SQL
statements as well as commit and rollback commands to the specified file, each on a new line. For
prepared statements the effective text resulting from substitution of parameter signs with their
values is written. Other event categories are logged as SQL comments ("-- " followed by the
category name). Exceptions and text are silently discarded. All SQL statements except the last
one will have a delimiter character ';' appended to them. This batch format works well with
WinSQL. The format is hardcoded, so if you want to make it configurable you'll have to patch my
patch or write your own :)