使用性能计数器的用户权限 [英] User Conncetions with Performance Counter

查看:72
本文介绍了使用性能计数器的用户权限的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

大家好,

我希望我的SQL中具有性能计数器的用户连接.

I want user connections in my sql with performance counter.

我写了这段代码:

将prf作为新的System.Diagnostics.PerformanceCounter("SQLServer:General Statistics","User Connections")

Dim prf As New System.Diagnostics.PerformanceCounter("SQLServer:General Statistics", "User Connections")

所以,prf.NextValue()是它的值.

So,prf.NextValue() is its value.

它给了我全部连接,但是我想查看每个用户的连接.

it gives me total connection,but i want to see each user connections.

你能帮我吗?

感谢您的答复

推荐答案

您好,goksuuu

Hi goksuuu

我非常确定不可能有一个性能计数器来连接各个用户.

I'm quite sure that it is not possible to have a performance counter for connections on individual users.

您可以通过运行sp_who存储过程来找到它们.

You could find them out by running the sp_who stored procedure.

致谢

Nico


这篇关于使用性能计数器的用户权限的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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