SQL Anywhere Studio Security Guide
Keeping Your Data Secure
Auditing database activity
You can use the Log Translation [dbtran] utility to retrieve audit information. You can access this utility from Sybase Central or from the command prompt. It operates on a transaction log to produce a SQL script containing all of the transactions, along with some information on what user executed each command. By using the -g
option, dbtran includes more comments containing the auditing information.
To ensure a complete and readable audit record, the -g
option automatically sets the following options:
-d Display output in chronological order.
-t Include trigger-generated operations in the output.
-a Include rolled back transactions in the output.
You can run the Log Translation Utility against a running database server or against a database log file.
To retrieve auditing information from a running database server
Make sure your user ID has DBA authority.
With the database server running, execute the following statement at a system command prompt:
dbtran -g -c "uid=DBA;pwd=SQL;..." -n asademo.SQL
For information about connection strings, see Connection parameters.
To retrieve auditing information from a transaction log file
Close the database server to ensure the log file is available.
At a system command prompt, execute the following statement to place the information from the file asademo.log and into the file asademo.SQL.
dbtran -g asademo.log
The -g
option includes auditing information in the output file.
For more information, see The Log Translation utility.