Subject Re: [ib-support] journalling
Author David K. Trudgett
On Friday 2002-02-22 at 10:19:54 +0100, Duilio Foschi wrote:

> I need a way to make a diary of all changes that were done to a given
> database by all users.
>
> Is there a way to do it ?

You could use that log manager product that another user pointed you
towards, or you could roll your own, as I am currently doing. I've
never used the log manager product, but it's probably the easier
option, especially if you have a lot of tables in the database.

My solution uses AFTER INSERT, AFTER UPDATE and AFTER DELETE triggers,
which call a stored procedure, which inserts a row into an audit
table. In the case of updates, I insert a row in the audit table for
each individual column that changes (mostly, only a small subset of
columns get changed in any one update operation).


David Trudgett