views:

63

answers:

2

I want to monitor all the DML commands that run on a particular table of my database in sql server profiler. Im using sql server 2008 R2

+6  A: 

Yes sure - you might want to check out this video series by Brad McGehee:

Mastering SQL Server Profiler - Video Training Course

It's very useful and teaches you the basics and some more advanced concepts of SQL Server Profiler. Highly recommended.

Or here's the 10-minute short version by Brent Ozar: SQL Server Profiler Tutorial Video

In SQL Server Profiler, when you create a new profile trace, you can define filters. You can limit the stats being collected by a ton of different criteria - one of them being the Object Name , e.g. the table name you want to check for.

See Profiler Filters for more information on that particular topic.

marc_s
Beat me to it! Thanks for the link to video - not seen that.
Ragster
+3  A: 

Depending upon your exact needs you might also want to look into extended events. This has several advantages over using SQL Profiler/ SQL Trace in terms of performance, flexibility of filters, and the information available.

If you do decide to investigate this further you might find my answer to another question useful for getting up and running.

Martin Smith