SQL Server – Database Diagram Permissions – “Day to Day”

Background

In an earlier post, SQL Server – Database Diagram Permissions ( Link ), spoke about veeting the need to grant db_owner privilege to allow users to diagram databases.

Exercise

Create Login & Grant Access to DB

Create a new login and granted that login access to the targeted database.

In our case, our target db is WideWorldImportersDW.

User without any object level access

Here is what is available to a user who has not been assigned object level permissions.

 

 

Grant user access to targeted objects

Script


USE [WideWorldImportersDW]
GO

grant select on [Fact].[Sale] to [ls]
go

grant select on [Dimension].[City] to [ls]
grant select on [Dimension].[Customer] to [ls]
grant select on [Dimension].[Date] to [ls]
grant select on [Dimension].[Employee] to [ls]
grant select on [Dimension].[Stock Item]  to [ls]
go

Diagram Objects – Post User granted object level access

Here is the view once user has been granted object level access.

Diagrammed Objects

Here is our objects diagrammed.

Summary

Proved that once a database is configured with database diagramming objects, users are able to diagram any objects they have been assigned read permissions.

 

Leave a Reply

Please log in using one of these methods to post your comment:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s