Find Memory Usage of Executing Procedures

To get the query memory usage of currently executing queries run the following: [cc lang=”sql”] SELECT TEXT ,query_plan ,requested_memory_kb ,granted_memory_kb ,used_memory_kb FROM sys.dm_exec_query_memory_grants emg CROSS APPLY sys.dm_exec_sql_text(sql_handle) CROSS APPLY sys.dm_exec_query_plan(emg.plan_handle) ORDER BY emg.requested_memory_kb DESC [/cc]

Continue reading ...

Featured Articles

 Site Author

  • Thanks for visiting!
css.php