I have a trouble in monitoring t-sql commands, I want to monitor just commands like: select, insert, update or delete. Can anyone help me?
            Asked
            
        
        
            Active
            
        
            Viewed 8,151 times
        
    3 Answers
6
            Pick a trace template (such as Tuning) and use a filter.
Either filter by a particular login (such as your own login or a service's login), or a particular database.
For instance, to filter by database: Under Trace properties -> Events tab -> Select show all columns. Set a Like filter on database name.
I find setting a filter on the number of Logical Reads of say > 10 reads, filters out most of the noise.
        Mitch Wheat
        
- 295,962
 - 43
 - 465
 - 541
 
3
            
            
        Download Express Profiler From CodePlex
You can get all your query after starting a trace. This can be used any machine.
        sudhansu63
        
- 6,025
 - 4
 - 39
 - 52
 
- 
                    1This is sooooo good. Beats having to install the clunky default SQL Profiler. – GONeale Sep 26 '13 at 12:20
 
2
            
            
        - Open Sql Profiler from: Programs -> Microsoft SQL Server 2008 R2 -> Performance Tools -> SQL Server Profiler
 - Click on "New Trace" and Logon into database engine
 - Click on "Show all events" checkbox
 - In the events tree expand "TSQL" and check SQL:BatchCompleted, then check "Show all columns" and check item "TextData"
 - Click Run button.
 
        Hossein POURAKBAR
        
- 1,073
 - 2
 - 15
 - 33