Reputation: 2108
Is it possible to check if user's roles on a SSRS contains rights to certain tasks?
Now I can only try to perform an operation and show an error if an user cannot perform the operation, but I want to inform an user about possible problems before he starts to do his job.
Upvotes: 0
Views: 125
Reputation: 13692
This will get you a list of permissions; you can filed down by username to see a single users or groups permissions.
select
dbo.Users.UserName,
dbo.Roles.RoleName,
substring(dbo.catalog.path,2,LEN(dbo.catalog.path)) FolderName
from
dbo.PolicyUserRole
left join dbo.Users
on dbo.Users.UserID=dbo.PolicyUserRole.UserID
left join dbo.Roles
on dbo.Roles.RoleID=dbo.PolicyUserRole.RoleID
inner join dbo.Catalog
on dbo.Catalog.PolicyID=dbo.PolicyUserRole.PolicyID
where
TYPE=1
Upvotes: 1