Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
| Author |
Topic |
|
AskSQLTeam
Ask SQLTeam Question
0 Posts |
Posted - 2003-04-02 : 06:27:09
|
| Ash writes "Is there a way to log all INSERT/UPDATE/DELETE commands performed against a database? I believe the Transaction Log only logs transactions, and not individual statements.The reason I'm asking is because I'm running an application that dumps data to a database, and I need to know what tables get updated, so that I can replicate this function in my own program.If I can't log these statements, what are your ideas on getting this done?" |
|
|
samsekar
Constraint Violating Yak Guru
437 Posts |
Posted - 2003-04-02 : 06:50:42
|
| You can use TRIGGERS on that table and insert those records into a separate table as logs.Sekar~~~~Success is not a destination that you ever reach. Success is the quality of your journey. |
 |
|
|
chadmat
The Chadinator
1974 Posts |
Posted - 2003-04-05 : 18:50:32
|
| Individual statements are still transactions, so the transaction log will log the, but you can't read the transaction log without a 3rd party utility.Sekar, triggers won't help him figure out which tables are being used, he would need to know that in order to create the trigger.You could use profiler, and monitor all of the sql statments. -Chad |
 |
|
|
|
|
|