select * from master..sysprocesses where hostname<>'' and dbid=db_id('training') 转载于:https://www.cnblogs.com/mikemao/archive/2008/11/12/1331973.html