简体   繁体   中英

sql 2005 server roles

On one of our sql 2005 servers we are no longer able to give any users server roles (ex. sysadmin). It appears to be successful both through the UI and through code. But when we check in the db and in the UI the role is unchecked and not shown for the user in the master db. Permissions don't seem to be the issue as we are testing this as system administrator levels of access. There are also no errors in the log.

Any ideas?

Thanks,

Brandon

Users in master have nothing to do with server level roles. Ccheck by looking into the proper catalogs: sys.server_principals and sys.server_role_members :

select r.name as [Role], p.name as [Member] 
from sys.server_role_members m
join sys.server_principals r on m.role_principal_id = r.principal_id
join sys.server_principals p on m.member_principal_id = p.principal_id
where r.name = 'sysadmin';

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM