<pre>select * from sys.sysusers (nolock) or
select * from sys.database_principals (nolock)</pre>
This will get you the list of "named" users of the database.
<pre>select * from sys.server_principals (nolock)
where type_desc = 'WINDOWS_LOGIN'</pre>
This will get you the list of users authorized by their Windows authentications. (This is probably what you really want.)
Last Wiki Answer Submitted: May 24, 2010 7:46 pm by Kccrosser3,830 pts.
If you live outside the United States, by submitting your email address you consent to having your personal data transferred to and processed in the United States.
Hi sir ,
Thnx for ur reply that was helpfull , but i want the users who are assigned to specific Shema name in a database.