有一些像用户名和选择语句一样的角色。
+============+========== | User name | Role | +============+==========
MS sql Server 2008
此查询应提供您要查找的信息。
select rp.name as database_role,mp.name as database_user from sys.database_role_members drm join sys.database_principals rp on (drm.role_principal_id = rp.principal_id) join sys.database_principals mp on (drm.member_principal_id = mp.principal_id)