You can use system table to get this information like ;
Select * from pubs.dbo.sysusers Where IsLogin = 1
I am confused with your question either you want to see the currently logins user on a database or just want to see which I mentioned in the above query.
I tried that also but it still returns rows which are not user anymore..... i am not sure how that happens.... the sysusers table has some rows in it that r not being shown in enterprise manager.
Could there something more to it.......
this is the sql i was using...
Select * from sysusers Where islogin = 1
and hasdbaccess = 1 and issqlrole = 0
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.