When I use SQL Server Profiler to track performance problems, I sometimes notice large differencesas much as 2 or 3 secondsbetween the duration for the SQL:BatchCompleted event and the SQL:StmtCompleted event. Why are the duration times different?
Generally speaking, the difference between a SQL:BatchCompleted event's duration time and a SQL:StmtCompleted event's duration time is how long each event takes to parse and compile a query. SQL Server can usually parse a...