.net - Designing a way to audit changes to tables -


i want able audit activity performed on db tables (updates, inserts etc). effective way design this? 1 solution have in mind have audit table every table , use sql triggers insert previous value before table updated new value.

sql server version 2008 include built-in option looking for. named cdc or change data capture. can more information in bol (officially book-on-line) in first link or blog in sec link:

there other options can use. in order choose best option need more information on system. if (1) can describe system architecture, , (2) information want store in auditing (do need user name or audit data self), (3) need keep history or events, (4) temporary needs or part of database structure (cdc create elements triggers , not fits temporary audit, better use extended event or profiler). cdc option audit data changes, if fits needs.


Comments

Popular posts from this blog

javascript - gulp-nodemon - nodejs restart after file change - Error: listen EADDRINUSE events.js:85 -

Fatal Python error: Py_Initialize: unable to load the file system codec. ImportError: No module named 'encodings' -

javascript - oscilloscope of speaker input stops rendering after a few seconds -