Search This Blog

Wednesday, 7 January 2015

Find Memory Usage (RAM) by Sql query

Tip #2 Memory Usage  (RAM) by Sql processes.

I am posting some of the most useful queries which help a dba/ developer to optimize database performance. Please reference to different Tips in other blogs as well.Following query will help in determine Memory usage in percentage by sql processes. Run the following query in your sql server query window:

SELECT (((m.total_physical_memory_kb - m.available_physical_memory_kb) / convert(FLOAT, m.total_physical_memory_kb)) * 100) AS memoryusage FROM sys.dm_os_sys_memory m GO