是否有平均执行时间的 SQL 服务器性能计数器? [英] Is there a SQL server performance counter for average execution time?

查看:48
本文介绍了是否有平均执行时间的 SQL 服务器性能计数器?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想调整生产 SQL 服务器.进行调整(例如更改并行度)后,我想知道它是否有助于或损害查询执行时间.

I want to tune a production SQL server. After making adjustments (such as changing the degree of parallelism) I want to know if it helped or hurt query execution times.

这似乎是一个明显的性能计数器,但在过去的半个小时里,我一直在搜索 Google 和 perfmon 中的计数器列表,但我一直无法找到 SQL 服务器的性能计数器来提供平均执行情况所有查询访问服务器的时间.相当于 ASP.NET 请求执行时间的 SQL Server.

This seems like an obvious performance counter, but for the last half hour I've been searching Google and the counter list in perfmon, and I have not been able to find a performance counter for SQL server to give me the average execution time for all queries hitting a server. The SQL Server equivalent of the ASP.NET Request Execution Time.

是否存在我遗漏的?是否有另一种有效的方法来监控服务器的平均查询时间?

Does one exist that I'm missing? Is there another effective way of monitoring the average query times for a server?

推荐答案

我不相信有 PerfMon 但在 SQL Server Management Studio 中有一个报告:

I don't believe there is a PerfMon but there is a report within SQL Server Management Studio:

右键单击数据库,选择报告 > 标准报告 > 对象执行统计.这将为您提供关于数据库中正在运行的内容、花费的时间、花费的内存/io 处理量等的一些非常好的统计数据.

Right click on the database, select Reports > Standard Reports > Object Execution Statistics. This will give you several very good statistics about what's running within the database, how long it's taking, how much memory/io processing it takes, etc.

您还可以在所有数据库的服务器级别运行此程序.

You can also run this on the server level across all databases.

这篇关于是否有平均执行时间的 SQL 服务器性能计数器?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆