Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
 
Log in  ::  Register  ::  Not logged in
 
 
 
        
Home       Members    Calendar    Who's On


Add to briefcase

How to find database,object,schema level permissions on a server Expand / Collapse
Author
Message
Posted Tuesday, March 12, 2013 6:47 AM
Forum Newbie

Forum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum Newbie

Group: General Forum Members
Last Login: Wednesday, June 5, 2013 8:47 AM
Points: 9, Visits: 44
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
Post #1429753
Posted Wednesday, March 13, 2013 8:17 AM
Old Hand

Old HandOld HandOld HandOld HandOld HandOld HandOld HandOld Hand

Group: General Forum Members
Last Login: Thursday, October 31, 2013 3:44 AM
Points: 314, Visits: 4,128
¥?ürz.§µññÿ (3/12/2013)
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


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.

Post #1430418
Posted Wednesday, March 13, 2013 12:59 PM
Forum Newbie

Forum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum Newbie

Group: General Forum Members
Last Login: Wednesday, June 5, 2013 8:47 AM
Points: 9, Visits: 44
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
Post #1430590
« Prev Topic | Next Topic »

Add to briefcase

Permissions Expand / Collapse