Monitoring query performance
We have already introduced many tools that can be used to get data on processing operations, using trace, performance counters and dynamic management views. The same tools can also be used to monitor query performance, and in this section we'll see how this can be done.
Monitoring queries with trace data
Regardless of the tool we use to collect it (SQL Server Profiler, ASTrace, XMLA, or Flight Recorder), trace data is the most important source of information on query-related operations. Trace data provides information on the internal operations of the Storage Engine and the Formula Engine, for example showing if aggregations are used or not or if calculations are evaluated in bulk mode or not.
The most important trace events for analyzing query performance are as follows (once again, the integer identifier for each event is shown in parentheses after its name):
Progress Report Begin (5) / Progress Report End (6) – there is only one subclass event that is relevant...