On Tue, Nov 14, 2000 at 02:44:21PM +1100, sonamc@stripped wrote:
> sasha@stripped wrote:
> > Sonam Chauhan wrote:
> I was hoping I could leverage the logs by extending the Database Driver <-->
> 'conversation' to pass an additional 'comment' parameter on every database query
> executed. This does mean additional coding for the DB API and the MySQL server.
> but it give admins the capability for fine-grained audits.
At least in MySQL 3.22.21, the queries are logged as they are sent to
the server, i.e. with SQL comments (tested with the update log).
So you could try to write something like:
SELECT whatever FROM my_table WHERE any_condition /* user: foobar */
and grep for '/* user: ' in the log when you want to search for such
rows. This method surely can extended to whatever you need in detail,
given comments are still passed to the logs in your version (and in
PS: Either the "internals" or "mysql" list is too much on the CC. I
just not sure which...