用于asp.net还原与恢复SqlServer数据库的KillSpid存储过程 CREATE PROCEDURE KillSpid(@dbName varchar(20)) AS BEGIN DECLARE @sql nvarchar(500) DECLARE @spid int SET @sql='DECLARE getspid CURSOR FOR SELECT spid FROM sysprocesses WHERE dbid=db_id('''+@dbName+''')' EXEC (@…