O'Reilly logo

Microsoft SQL Server 2012 Performance Tuning Cookbook by Bihag Thaker, Ritesh Shah

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Monitoring current query execution statistics

In order to perform query tuning on production database server, you need to identify those resource-consuming queries and the source from where they are coming. For this, you need to monitor the incoming query requests and examine their execution time, number of read/write operations, and so on.

SQL Server has dedicated a separate category of DMVs and DMFs to query execution statistics. These DMVs and DMFs provide a wide range of statistics on query execution requests. The names of these execution-related DMVs and DMFs are generally prefixed by sys.dm_exec_. By examining the results returned by these DMVs and DMFs, you can find out long-running and resource-consuming queries, and pick them up for query ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required