22,209
社区成员
发帖
与我相关
我的任务
分享
--列出所有活动的用户
SP_WHO 'active'
--列出某个特定用户的信息
SP_WHO 'sa'
select * from sys.sysprocesses a
where a.spid in (select session_id from sys.dm_exec_sessions
where is_user_process = 1)
select session_id,cpu_time
from sys.dm_exec_requests
select login_time from sys.sysprocesses where spid=1
服务器的启动时间