Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 SQL Server Administration (2000)
 Tracing long running queries

Author  Topic 

nishithrn
Yak Posting Veteran

58 Posts

Posted - 2003-05-05 : 04:03:44
Hello,

Can anyone pls. tell me what paramaters are to be used in Profiler/Perf. Monitor to trace a query which takes a long time to execute and also takes up a lot of cpu space.

Regards

franco
Constraint Violating Yak Guru

255 Posts

Posted - 2003-05-05 : 09:10:28
You have an infinity of parameters, here you can find some useful things:
General:
http://www.sql-server-performance.com/performance_monitor_tips.asp
CPU:
http://www.sql-server-performance.com/performance_monitor_counters.asp
I/O:
http://www.sql-server-performance.com/performance_monitor_counters_io.asp
Memory:
http://www.sql-server-performance.com/performance_monitor_counters_memory.asp
Network:
http://www.sql-server-performance.com/performance_monitor_counters_network.asp
SQL Server:
http://www.sql-server-performance.com/performance_monitor_counters_sql_server.asp

Of course you can also investigate thru Query Execution Plan Analysis:
http://www.sql-server-performance.com/query_execution_plan_analysis.asp

HTH

Franco
Go to Top of Page

nr
SQLTeam MVY

12543 Posts

Posted - 2003-05-05 : 11:05:40
Do you know which query takes a long time?
If not then you can use

Stored procedure rpc completed
tsql sql batch completed

put in a filter for duration to get long running ones.

This will give you the queries that are causing problems.
Now put them in query analyser and loko at the expected execution plan.
If you need the actual plan and they do updates run on a test system or in a transaction.


==========================================
Cursors are useful if you don't know sql.
DTS can be used in a similar way.
Beer is not cold and it isn't fizzy.
Go to Top of Page
   

- Advertisement -