Re: select from one db only
From: Kalen Delaney (replies_at_public_newsgroups.com)
Date: 08/12/03
- Next message: AJAY R: "Re: how to monitor table changes"
- Previous message: Dinesh.T.K: "Re: select from one db only"
- In reply to: Dinesh.T.K: "Re: select from one db only"
- Next in thread: Doug: "Re: select from one db only"
- Reply: Doug: "Re: select from one db only"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
Date: Mon, 11 Aug 2003 16:40:42 -0700
Those databases are available to anyone who can login to the server because
there is a 'guest' user defined. You should never remove guest from master
or tempdb, but you can remove guest from pubs and northwind if you really
don't want a user to have access. But why not, you might ask, those
databases are just for 'trying things out'.
use pubs
exec sp_dropuser guest
use northwind
exec sp_dropuser guest.
-- HTH ---------------- Kalen Delaney SQL Server MVP www.SolidQualityLearning.com "Dinesh.T.K" <tkdinesh@nospam.mail.tkdinesh.com> wrote in message news:#V12M3FYDHA.2648@TK2MSFTNGP09.phx.gbl... > Doug, > > >>>Is there a way > > that I can make it so he can only see the > > one db and not the others? > > No.He can see those system databases and sample databases because its common > knowledge that in a default SQL Server installation these are bound to be > there.You can however restrict "seeing" other user databases.However, this > privilege is available only via Query Analyzer while Enterprise manager > displays all user databases.The user will be belonging to the public, by > default and thats why he can SELECT from the various tables in system/sample > databases.You can however DENY permissions.For example, to deny the user > 'test' from doing any operation on master..sysobjects, you log in as > sysadmin and do: > > USE master > GO > DENY ALL ON sysobjects TO test > > More details on the BooksOnLine topic 'DENY' > > > -- > Dinesh. > SQL Server FAQ at > http://www.tkdinesh.com > > "Doug" <dag@its.msstate.edu> wrote in message > news:0b9301c36053$03a01240$a001280a@phx.gbl... > > Newbie question??? > > > > I created a login for a user. > > His default db is the only db that > > I want him to see. He does not have > > any server roles and database access > > only to the one db. When this user > > runs Query Analyzer, he is able to > > see and select from the other dbs (master, > > pubs, Northwind etc...). Is there a way > > that I can make it so he can only see the > > one db and not the others? > >
- Next message: AJAY R: "Re: how to monitor table changes"
- Previous message: Dinesh.T.K: "Re: select from one db only"
- In reply to: Dinesh.T.K: "Re: select from one db only"
- Next in thread: Doug: "Re: select from one db only"
- Reply: Doug: "Re: select from one db only"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
Relevant Pages
|