如何查看sql server数据库连接数

清华大佬耗费三个月吐血整理的几百G的资源,免费分享!....>>>

SELECT * FROM 
[Master].[dbo].[SYSPROCESSES] WHERE [DBID] 
IN 
(
  SELECT 
   [DBID]
  FROM 
   [Master].[dbo].[SYSDATABASES] 
  WHERE 
   NAME='databaseName'
)