Isolate an user to one DB

Last post 09-09-2008 8:53 AM by ghemant. 4 replies.
Page 1 of 1 (5 items)
Active Topics My Discussions Unanswered Sort Posts: Previous Next
  • 09-08-2008 8:14 AM

    Isolate an user to one DB

    Hy,

    I want to create a new user (TEST) and a new DB (TEST_DB).
    I set this user (TEST) db_owner of this DB (TEST_DB).

    is it possible that user (TEST) can see only your DB (TEST_DB), and no other...if this user create new source ODBC or make select from sys.databases, ecc?

     Thanks for attention

     Alessandro M.

     

  • 09-08-2008 6:30 PM In reply to

    Re: Isolate an user to one DB

    Welcome to the forum....

    If you don't grant the access to the other dbs, user can't see them...

    or you deny the view access for other dbs if you want to make sure....

    In sql 2000, user can all the dbs even the access is not granted.

    MohammedU.
    Microsoft SQL Server MVP
    Moderator
    SQL-Server-Performance.com

    All postings are provided “AS IS” with no warranties for accuracy.
  • 09-09-2008 1:41 AM In reply to

    Re: Isolate an user to one DB

    My sql version is 2005.

    I want that this user can access and view only his DB.
    is it possible that he can't view master and tempdb (sysdatabases)?

     thanks

     Alessandro M.

  • 09-09-2008 7:12 AM In reply to

    Re: Isolate an user to one DB

     Dear Alessandro,

     You can create new user and assign access only to his db. Then he will have access only to his db BUT he will be able to see all other db's in the Management Studio (only db names) but can't see the tables in it. Also this user will have access to Master, Msdb and Tempdb, he will have the right to do select also.

    This is same in SQL 2008 also. experts please correct me if am wrong.

    Thanks

    John

     

  • 09-09-2008 8:53 AM In reply to

    Re: Isolate an user to one DB

    True,  when ever a new user is created it is added to public role by default. While creating a user if you set it for the particular db access he/she can access that particular database only (including system databases). Refer http://www.databasejournal.com/features/mssql/article.php/1478701 or BOL for more information on this.

     

    Hemantgiri S. Goswami | MS SQL Server MVP
    -------------------------
    "Humans don't have Caliber to PASS TIME , Time it self Pass or Fail Humans" - by Hemantgiri S. Goswami

    http://hemantgirisgoswami.blogspot.com
    http://forums.surat-user-group.org/

    View Hemantgiri S. Goswami's profile on LinkedIn

    Disclaimer: This post is provided as is, for the sake of knowledge sharing only.
Page 1 of 1 (5 items)
Active Topics   My Discussions    Unanswered Posts


© 2000 - 2007 vDerivatives Limited All Rights Reserved.