Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
 
Log in  ::  Register  ::  Not logged in
 
 
 
        
Home       Members    Calendar    Who's On


Add to briefcase

Profiler Trace duration? Expand / Collapse
Author
Message
Posted Saturday, August 03, 2013 6:21 AM
Ten Centuries

Ten CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen Centuries

Group: General Forum Members
Last Login: 2 days ago @ 5:15 AM
Points: 1,015, Visits: 2,843
Hi,

I have transfer data into table from trace file , after that i want check duration of praticulare events..

I want to know as bleow query display how much milliseond or microsecond from trace table?

SELECT TextData, Duration, CPU
FROM trace_table_name
WHERE EventClass = 12 -- SQL:BatchCompleted events
AND CPU < (Duration * 1000)

thanks
ananda
Post #1480685
Posted Saturday, August 03, 2013 11:40 AM


SSC-Dedicated

SSC-DedicatedSSC-DedicatedSSC-DedicatedSSC-DedicatedSSC-DedicatedSSC-DedicatedSSC-DedicatedSSC-DedicatedSSC-DedicatedSSC-DedicatedSSC-DedicatedSSC-DedicatedSSC-Dedicated

Group: General Forum Members
Last Login: Today @ 8:11 AM
Points: 36,015, Visits: 30,302
ananda.murugesan (8/3/2013)
Hi,

I have transfer data into table from trace file , after that i want check duration of praticulare events..

I want to know as bleow query display how much milliseond or microsecond from trace table?

SELECT TextData, Duration, CPU
FROM trace_table_name
WHERE EventClass = 12 -- SQL:BatchCompleted events
AND CPU < (Duration * 1000)

thanks
ananda


I guess I don't understand what that last part of the WHERE clause is for. Are you just trying to find things where parallelism did NOT take place based on a CPU/Duration comparison? If so, that's probably faulty logic since CPU time can still be less than duration even though parallelism took place.


--Jeff Moden
"RBAR is pronounced "ree-bar" and is a "Modenism" for "Row-By-Agonizing-Row".

First step towards the paradigm shift of writing Set Based code:
Stop thinking about what you want to do to a row... think, instead, of what you want to do to a column."

"Change is inevitable. Change for the better is not." -- 04 August 2013
(play on words) "Just because you CAN do something in T-SQL, doesn't mean you SHOULDN'T." --22 Aug 2013

Helpful Links:
How to post code problems
How to post performance problems
Post #1480707
« Prev Topic | Next Topic »

Add to briefcase

Permissions Expand / Collapse