Please start any new threads on our new site at We've got lots of great SQL Server experts to answer whatever question you can come up with.

Our new SQL Server Forums are live! Come on over! We've restricted the ability to create new threads on these forums.

SQL Server Forums
Profile | Active Topics | Members | Search | Forum FAQ
Save Password
Forgot your Password?

 All Forums
 SQL Server 2005 Forums
 SQL Server Administration (2005)
 Grant view for a specific database
 Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

Starting Member

47 Posts

Posted - 09/11/2013 :  11:17:12  Show Profile  Reply with Quote
How can i grant view only to one database for a user?

Should i have to grant view to ANY and then individually DENY VIEW for other databases?



Starting Member

47 Posts

Posted - 09/11/2013 :  12:29:19  Show Profile  Reply with Quote
never mind i was able to get it from below

"This is possible for a single user login as you can only asign ownership of a database to a single user.
Should be ok for most small hosting situations. This is how I achieved it under SQL server 2008...

1. Right click the users logon under the users database if they exist and remove
(Note: Do not remove the user from under the main security login)

2. Run the following query

USE <customersdatabase>

ALTER AUTHORIZATION ON DATABASE::<customerdatabase> to <customerlogin>


DENY VIEW ANY DATABASE TO <customerlogin>"
Go to Top of Page
  Previous Topic Topic Next Topic  
 Reply to Topic
 Printer Friendly
Jump To:
SQL Server Forums © 2000-2009 SQLTeam Publishing, LLC Go To Top Of Page
This page was generated in 0.02 seconds. Powered By: Snitz Forums 2000