I ran this query...SELECT TOP 100total_worker_time, total_worker_time/execution_count AS Avg_CPU_Time ,execution_count ,total_elapsed_time ,total_elapsed_time/execution_count as AVG_Run_Time ,(SELECT text FROM sys.dm_exec_sql_text(sql_handle) ) AS query_text FROM sys.dm_exec_query_stats --pick your criteriaORDER BY total_worker_time DESC
To find the most CPU intensive queries in the database. Several of the results are the creation of triggers... CREATE TRIGGER tr_Students_Audit ON Students FOR INSERT, UPDATE, DELETE AS DECLARE @bit INT , @field INT , <snip>
And they've been run millions of times in about one week. I checked with our development team and nobody knows what is causing them to run. Has anyone come across this before and know what could be causing it?