SQL Server Performance

DMV to replace sp_who and pass specific database

Discussion in 'SQL Server 2005 General DBA Questions' started by BikeBoy, Jan 20, 2006.

  1. BikeBoy New Member

    Hi,

    Can someone remind me what's the DMV that replaces sp_who in sql 2005? Supposed to be able to pass the database name to see spids on specific database.
    I though it was dm_exec_connections, but there's no database param option.

    Thanks
  2. satya Moderator

    I don't see any replacement to SP_who in SQL 2005, but there are few DMVs added to get more information.

    Let me see whether we can get more information about what you're after.

    Satya SKJ
    Contributing Editor & Forums Moderator
    http://www.SQL-Server-Performance.Com
    This posting is provided “AS IS” with no rights for the sake of knowledge sharing.
  3. BikeBoy New Member

    Here's how to do it:


    select * from sys.dm_exec_requests
    where database_id = db_id ('master')

Share This Page