32

What is the unit of the Duration column in SQL Profiler? I thought it was milliseconds but in the following Profiler row I found it contradicting with start and end time:

spid=163    
duration=11310646
starttime=2010-04-06 17:45:24.480
endtime=2010-04-06 17:45:35.790
reads=152
writes=2
cpu=16
eventclass=12
textdata= DELETE FROM dbo.[Icon] WHERE Id = 20087 

FYI, I am using SQL Server 2008.

Luke Girvin
  • 13,221
  • 9
  • 64
  • 84
Mubashar
  • 12,300
  • 11
  • 66
  • 95
  • The question [SQL Profiler CPU / duration units](http://stackoverflow.com/questions/976628/) gives a detailed answer – surfmuggle Nov 07 '16 at 12:17

1 Answers1

60

I found the answer here. It says

In SQL Server 2005 and later, the SQL Server Profiler graphical user interface displays the Duration column in milliseconds by default, but when a trace is saved to either a file or a database table, the Duration column value is written in microseconds

I was watching them after saving the trace file in database.

trejder
  • 17,148
  • 27
  • 124
  • 216
Mubashar
  • 12,300
  • 11
  • 66
  • 95
  • This answer was for version 2008 may be now it has been changed. May be now there is some config which may change this behavior. – Mubashar Jul 11 '17 at 23:35