SQL Server Performance

TSQL to list the most used query plans

Discussion in 'Other SQL Server Blogs around the Web' started by Anonymous, Sep 28, 2007.

  1. Anonymous New Member

    select TOP 100 objtype, p.size_in_bytes, LEFT([sql].[text], 100) as [text] from sys.dm_exec_cached_plans p outer apply sys.dm_exec_sql_text (p.plan_handle) sql ORDER BY usecounts DESC...(<a href="http://sqlserver-qa.net/blogs/t-sql/archive/2007/09/28/2255.aspx">read more</a>)<img src="http://sqlserver-qa.net/aggbug.aspx?PostID=2255" width="1" height="1">

Share This Page