In SQL Server 2008, you have change tracking that you can track when an insert, update, or delete occurs. This will track that an event has occurred that is recorded and, possibly, which columns were changed, but not the values ββ(before and after). This is typically used to perform bulk processes with known modified data.
In change tracking, you set a retention period for storing changes, usually a period that ensures that any processing of the tracked tables is within the retention period.
In addition, you have (again, in SQL 2008) Change Data Capture, which is more verbose and records the actual changes. This, however, is only a function of the enterprise.
You can easily create a .NET application to run change tracking requests or change data .
Here is a link to more information on how
Change Tracking
Change data collection
For the most part, change tracking is likely to be the best option - plus it works on all versions of SQL Server 2008.
If you want to achieve this in 2005 or lower, you can basically create tables for each table that you want to track, and have a trigger to insert values ββinto the tracking table when you insert, update, delete. Then try to clear this. This is mainly change tracking.
Coolcoder
source share