摘要: select er.session_id, CAST(csql.text AS varchar(255)) AS CallingSQLfrom master.sys.dm_exec_requests er WITH (NOLOCK) CROSS APPLY MASTER.sys.fn_g... 阅读全文
posted @ 2015-03-06 15:40 xfyn 阅读(1375) 评论(0) 推荐(0) 编辑
摘要: SELECT * FROM master..sysprocesses WHERE dbid=DB_ID('db')db换成对应的数据库名即可断开所有活动连接的存在过程方法ALTER PROC [dbo].[P_KillConnections] @dbname VARCHAR(200)AS D... 阅读全文
posted @ 2015-03-06 15:39 xfyn 阅读(775) 评论(0) 推荐(0) 编辑