Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

DB level permissions

Posted on 2010-09-16
6
Medium Priority
?
353 Views
Last Modified: 2012-05-10
are these 2 talking about the same permissions?

sp_dbfixedrolepermission -- brings back 105 records
SELECT * FROM fn_my_permissions (NULL, 'DATABASE') -- brings back 61 records
0
Comment
Question by:anushahanna
  • 3
  • 3
6 Comments
 
LVL 25

Accepted Solution

by:
DBAduck - Ben Miller earned 2000 total points
ID: 33696030
No they are not the same.  The first one simply tells you what permissions each fixed db role has given to it.

The second is more contextual to you and what you have permissions on for that database.
0
 
LVL 6

Author Comment

by:anushahanna
ID: 33710094
so if a sysadmin runs it, should he/she get 105 rows back for the second query?
0
 
LVL 25

Expert Comment

by:DBAduck - Ben Miller
ID: 33710097
No, because it will just show what he/she has permissions on and does not correspond to the db fixed roles.  So the results will vary.
0
Prepare for your VMware VCP6-DCV exam.

Josh Coen and Jason Langer have prepared the latest edition of VCP study guide. Both authors have been working in the IT field for more than a decade, and both hold VMware certifications. This 163-page guide covers all 10 of the exam blueprint sections.

 
LVL 6

Author Comment

by:anushahanna
ID: 33728775
OK.

doesn't a sysadmin 'implicitly' have permission on 'all' that is possible in SQL Server?
0
 
LVL 25

Expert Comment

by:DBAduck - Ben Miller
ID: 33731340
Yes, that is correct.  There is nothing that a sysadmin cannot do on a SQL Server.
0
 
LVL 6

Author Comment

by:anushahanna
ID: 33749901
OK. but sorry, I am not getting it, in that reason, should not the sysadmin have all the 105 permissions mentioned in dbfixedrolepermission sp?

thanks dbaduck
0

Featured Post

Hire Technology Freelancers with Gigs

Work with freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely, and get projects done right.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

For both online and offline retail, the cross-channel business is the most recent pattern in the B2C trade space.
A Stored Procedure in Microsoft SQL Server is a powerful feature that it can be used to execute the Data Manipulation Language (DML) or Data Definition Language (DDL). Depending on business requirements, a single Stored Procedure can return differe…
Viewers will learn how to use the INSERT statement to insert data into their tables. It will also introduce the NULL statement, to show them what happens when no value is giving for any given column.
Viewers will learn how to use the UPDATE and DELETE statements to change or remove existing data from their tables. Make a table: Update a specific column given a specific row using the UPDATE statement: Remove a set of values using the DELETE s…

927 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question