I’m trying to create some functionality that keeps an audit trail of how data in a given user form has been changed over time, with a dated audit at the foot of that page. For example:
02/04/09 21:49 Name changed from ‘Tom’ to ‘Chris’.
I’m doing this by storing the data in it’s present format in the session and then on save checking whether there are any differences in the data being stored. If there are, I’m storing the data how it was before the latest edit in a table called history, and storing the new values in the current user table.
Is this the best approach to be taking?
One suggestion; this would be relatively easy to do in a database trigger. In that case, you would never have to worry about whether the code running the update remembers to add a history record.