DECLARE @date DATETIME2
DECLARE @count INT
SET @count = 1
SET @date = SYSUTCDATETIME()
WHILE @count < 1000000
BEGIN
--RAISERROR ('%d',0,1, @count) WITH NOWAIT
--PRINT @count
SET @count = @count + 1
END
SELECT DATEDIFF(MICROSECOND, @date, SYSUTCDATETIME()) / 1000000.
DECLARE @count INT
SET @count = 1
SET @date = SYSUTCDATETIME()
WHILE @count < 1000000
BEGIN
--RAISERROR ('%d',0,1, @count) WITH NOWAIT
--PRINT @count
SET @count = @count + 1
END
SELECT DATEDIFF(MICROSECOND, @date, SYSUTCDATETIME()) / 1000000.