SQL Server 2005查看数据库用户权限 无 use yourdbgoselect DbRole = g.name, MemberName = u.name, MemberSID = u.sid from sys.database_principals u, sys.database_principals g, sys.database_role_members m where g.principal_id = m.role_principal_i
SQL Server 2005查看数据库用户权限use yourdb go select DbRole = g.name, MemberName = u.name, MemberSID = u.sid from sys.database_principals u, sys.database_principals g, sys.database_role_members m where g.principal_id = m.role_principal_id and u.principal_id = m.member_principal_id order by 1, 2 go
use master go select SrvRole = g.name, MemberName = u.name, MemberSID = u.sid from sys.server_principals u, sys.server_principals g, sys.server_role_members m where g.principal_id = m.role_principal_id and u.principal_id = m.member_principal_id order by 1, 2 go
use yourdb go exec sp_helprotect @username = 'user name' go
声明:本网页内容旨在传播知识,若有侵权等问题请及时与本网联系,我们将在第一时间删除处理。TEL:177 7030 7066 E-MAIL:11247931@qq.com