How to tell which queries are causing high CPU

lrobbinslrobbins Posts: 9
edited January 8, 2014 5:38AM in SQL Monitor Previous Versions
Is there a way in RedGate monitor to tell which queries are causing high CPU on a SQL server?

Comments

  • Brian DonahueBrian Donahue Posts: 6,590 Bronze 1
    Hello,

    CPU usage corresponds more to SQL Server system processes, so if you first get a list of processes, you can check the CPU cycles they use and then hopefully you can work out which queries correspond to which processes.

    Running this query against the master database should show the CPU:
    SELECT * FROM sysprocesses
    

    If you just want to see if the query is optimal, you can use the SQL Server Profiler (that comes with SQL Server's management tools) and run the query through the execution plan wizard and that should tell you if you can improve the query.
Sign In or Register to comment.