http://www.sqlservercentral.com/blogs/sql_server_dba/2012/04/10/sql-database-roles-and-members/

Printed 2014/09/01 09:05PM

SQL Database roles and members

2012/04/10

Q. How can I obtain the members of a role within a database?

A.  One method is to use sp_helprolemember

 

EXEC mydatabase.dbo.sp_helprolemember

--returns 
DBRole		MemberName		MemberSID
My_Admin_Role	DOMAIN\muUser	0x010500000000000515000000313CF1C8B4034LF676BJA5EE7C0D0000

For a comprehensive security audit on database roles – read Powershell sql server security audit


Copyright © 2002-2014 Simple Talk Publishing. All Rights Reserved. Privacy Policy. Terms of Use. Report Abuse.