Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
Author |
Topic |
AgaK
Yak Posting Veteran
86 Posts |
Posted - 2010-07-12 : 16:50:37
|
Hi,I am looking for the SQL 2008 version of the following 2 views: SYS.SYSPERFINFO and sys.dm_os_performance_countersI have very usefull queries that work in SQL 2005 but not 2008.ThanksAk--Buffer ManagerSELECT object_name,counter_name,cntr_value,(cntr_value*8)/1024 as inMBFROM SYS.SYSPERFINFO WHEREOBJECT_NAME LIKE '%:BUFFER MANAGER%' AND(COUNTER_NAME like '%TARGET PAGES%' ORCOUNTER_NAME like '%TOTAL PAGES%' ORCOUNTER_NAME like '%DATABASE PAGES%' ORCOUNTER_NAME like '%STOLEN PAGES%' ORCOUNTER_NAME like '%FREE PAGES%')ORDER BY cntr_value DESCselect (a.cntr_value * 1.0 / b.cntr_value) * 100.0 [Buffer Cache Hit Ratio]from (select * from sys.dm_os_performance_counterswhere counter_name like '%Buffer cache hit ratio%') ajoin(select * from sys.dm_os_performance_counterswhere counter_name like '%Buffer cache hit ratio base%') bon a.object_name = b.object_name |
|
|
|
|