March 12, 2013 at 6:47 am
Hi...any one can provide the solution please it's very urgent
i need a tsql script for SQL SERVER 2005
Requirements:
I have 2 user accounts for the both accounts i need to find the all the permissions.
Like...
•The 2 users are mapped to which databases on the server?
•What are the databases names?
•What kind of permissions having on the mapped databases?
•For each database i need to find all the permissions like object level, schema level....etc.....?
Thanks
March 13, 2013 at 8:17 am
¥?ürz.§µññÿ (3/12/2013)
Hi...any one can provide the solution please it's very urgenti need a tsql script for SQL SERVER 2005
Requirements:
I have 2 user accounts for the both accounts i need to find the all the permissions.
Like...
•The 2 users are mapped to which databases on the server?
•What are the databases names?
•What kind of permissions having on the mapped databases?
•For each database i need to find all the permissions like object level, schema level....etc.....?
Thanks
I think you may need to word your question differently without it looking like your trying to offload your work on folks?
At the very least, you should come back with something you have tried.
In any case, I can point you to the Security Catalog Views in Books Online and frankly, a little googling will
probably give you some good starting point scripts.
March 13, 2013 at 12:59 pm
Hi...friends.........This script gives all the permissions
Try this......very useful
select USER_NAME(p.grantee_principal_id) AS principal_name,
dp.type_desc AS principal_type_desc,
p.class_desc,
OBJECT_NAME(p.major_id) AS object_name,
p.permission_name,
p.state_desc AS permission_state_desc
from sys.database_permissions p
inner JOIN sys.database_principals dp
on p.grantee_principal_id = dp.principal_id
Viewing 3 posts - 1 through 2 (of 2 total)
You must be logged in to reply to this topic. Login to reply
This website stores cookies on your computer.
These cookies are used to improve your website experience and provide more personalized services to you, both on this website and through other media.
To find out more about the cookies we use, see our Privacy Policy