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 |
california6
Starting Member
38 Posts |
Posted - 2009-03-10 : 14:15:31
|
I have one table which contains application admin related settings. this table gets updated by the application on very frequent bases. i was wondering, is there a way, i just monitor the changes against this table from profiler? Is this possible? If yes, can someone please share how? if not, then what other alternatives do i have?Many thanks in advance.Cali |
|
sodeep
Master Smack Fu Yak Hacker
7174 Posts |
Posted - 2009-03-10 : 14:18:34
|
Use Triggers instead. |
 |
|
california6
Starting Member
38 Posts |
Posted - 2009-03-10 : 14:21:17
|
But triggers can not log what all changes happened on this table and though of using profiler.Cali |
 |
|
sodeep
Master Smack Fu Yak Hacker
7174 Posts |
Posted - 2009-03-10 : 14:26:33
|
quote: Originally posted by california6 But triggers can not log what all changes happened on this table and though of using profiler.Cali
Yes you can with AFTER TRIGGER to log table. Is your question about DDL or DML changes to table? |
 |
|
mfemenel
Professor Frink
1421 Posts |
Posted - 2009-03-10 : 15:10:47
|
In profiler you can filter the textdata column like this %procname%. Might take some tinkering to get it just right but that's the general approach. Now the other suggestions in this post are definitely a better approach if you're going to need this on an ongoing basis.Mike"oh, that monkey is going to pay" |
 |
|
california6
Starting Member
38 Posts |
Posted - 2009-03-10 : 17:12:30
|
sodeep - yes my question was, i would like to have a log of who's changing my table and what host are they coming from. if after trigger can do this, that will be great. but i do not know more about after trigger. are there any reference for this?thanks again,Cali |
 |
|
sodeep
Master Smack Fu Yak Hacker
7174 Posts |
Posted - 2009-03-10 : 22:42:18
|
quote: Originally posted by california6 sodeep - yes my question was, i would like to have a log of who's changing my table and what host are they coming from. if after trigger can do this, that will be great. but i do not know more about after trigger. are there any reference for this?thanks again,Cali
You still didn't answer my question? Is it only DML related or DDL ? You can use Suser_name to capture username and getdate() to log time.You can seearch in here as there are plenty of examples. |
 |
|
|
|
|