SQL Clone
SQLServerCentral is supported by Redgate
 
Log in  ::  Register  ::  Not logged in
 
 
 


Find Top 10 consumers of memory from Buffer Pool


Find Top 10 consumers of memory from Buffer Pool

Author
Message
akhamoshioke
akhamoshioke
SSC-Enthusiastic
SSC-Enthusiastic (178 reputation)SSC-Enthusiastic (178 reputation)SSC-Enthusiastic (178 reputation)SSC-Enthusiastic (178 reputation)SSC-Enthusiastic (178 reputation)SSC-Enthusiastic (178 reputation)SSC-Enthusiastic (178 reputation)SSC-Enthusiastic (178 reputation)

Group: General Forum Members
Points: 178 Visits: 468
Comments posted to this topic are about the item Find Top 10 consumers of memory from Buffer Pool
muhammadm
muhammadm
SSC Rookie
SSC Rookie (30 reputation)SSC Rookie (30 reputation)SSC Rookie (30 reputation)SSC Rookie (30 reputation)SSC Rookie (30 reputation)SSC Rookie (30 reputation)SSC Rookie (30 reputation)SSC Rookie (30 reputation)

Group: General Forum Members
Points: 30 Visits: 42
I get an error
Msg 207, Level 16, State 1, Line 4
Invalid column name 'single_pages_kb'.
Msg 207, Level 16, State 1, Line 10
Invalid column name 'single_pages_kb'.
ccp-brabra
ccp-brabra
Forum Newbie
Forum Newbie (4 reputation)Forum Newbie (4 reputation)Forum Newbie (4 reputation)Forum Newbie (4 reputation)Forum Newbie (4 reputation)Forum Newbie (4 reputation)Forum Newbie (4 reputation)Forum Newbie (4 reputation)

Group: General Forum Members
Points: 4 Visits: 108
That means you are either running SQL2012 or 2014.
To get the same information for those you would execute the following.
-- Top 10 consumers of memory from Buffer Pool
SELECT TOP 10
[type]
, SUM(pages_kb) AS memory_in_kb
FROM
sys.dm_os_memory_clerks
GROUP BY
type
ORDER BY
SUM(pages_kb) DESC ;


akhamoshioke
akhamoshioke
SSC-Enthusiastic
SSC-Enthusiastic (178 reputation)SSC-Enthusiastic (178 reputation)SSC-Enthusiastic (178 reputation)SSC-Enthusiastic (178 reputation)SSC-Enthusiastic (178 reputation)SSC-Enthusiastic (178 reputation)SSC-Enthusiastic (178 reputation)SSC-Enthusiastic (178 reputation)

Group: General Forum Members
Points: 178 Visits: 468
--A slight modification so it displays the memory used in MB as well.

-- Top 10 consumers of memory from Buffer Pool
SELECT TOP 10
[type] AS OBJECT_TYPE
, SUM(pages_kb) AS memory_in_kb
, (SUM(pages_kb) / 1024) AS memory_in_MB
FROM
sys.dm_os_memory_clerks
GROUP BY
type
ORDER BY
SUM(pages_kb) DESC ;
muhammadm
muhammadm
SSC Rookie
SSC Rookie (30 reputation)SSC Rookie (30 reputation)SSC Rookie (30 reputation)SSC Rookie (30 reputation)SSC Rookie (30 reputation)SSC Rookie (30 reputation)SSC Rookie (30 reputation)SSC Rookie (30 reputation)

Group: General Forum Members
Points: 30 Visits: 42
thank you it works I am testing SQL 2012
Go


Permissions

You can't post new topics.
You can't post topic replies.
You can't post new polls.
You can't post replies to polls.
You can't edit your own topics.
You can't delete your own topics.
You can't edit other topics.
You can't delete other topics.
You can't edit your own posts.
You can't edit other posts.
You can't delete your own posts.
You can't delete other posts.
You can't post events.
You can't edit your own events.
You can't edit other events.
You can't delete your own events.
You can't delete other events.
You can't send private messages.
You can't send emails.
You can read topics.
You can't vote in polls.
You can't upload attachments.
You can download attachments.
You can't post HTML code.
You can't edit HTML code.
You can't post IFCode.
You can't post JavaScript.
You can post emoticons.
You can't post or upload images.

Select a forum

































































































































































SQLServerCentral


Search