I was wondering what others here think about storing changes to every record into some kind of audit trail table? Is this a good and reasonable design or waste of database storage? Hi, Dmitry,
As Walter mentioned, many applications have requirements to track and store changes - to see "whodunnit and when", and also to re-create history.
Here's a little story - several years ago a report I developed suddently went haywire....and I spent hours looking everyone except the one place I should have looked. The DBA (of all people) changed a critical configuration to demonstrate something to someone, and then didn't change it back. There was no history to prove he touched it (except he confessed later). An audit trail would have permitted me to query the log for all changes since the last day I knew the report was running properly.
Audit trails are like insurance....you pay something for quite a long time, but when you need it, you NEED it.
So in any serious production application, I'll turn your original question around (and it will be a rhetorical question) - is there any good reason NOT to store changes? :)