You are here: Re: ? about users « MsSQL Server « IT news, forums, messages
Re: ? about users

Posted by Erland Sommarskog on 01/07/08 22:19

Brian (brian@work) writes:
> How do I setup a user to access the my sql server database. I do not want
> to give him the admin account login.

It would certainly help to know more about your database and your server
and the context it exists in. And what you want the user to do in the
database.

But assuming that your user has a Windows login to connect with you would
do:

CREATE LOGIN [Domain\Name] FROM WINDOWS;
go
USE db;
go
CREATE USER [Domain\Name]

Then you would assign the user the permissions he need. (Which I can't
detail, because I don't know what he needs.)

If you are in a workgroup, it's probably better to use an SQL login.

And, oh, the above syntax is for SQL 2005; another thing you did not detail
was the SQL Server version.


--
Erland Sommarskog, SQL Server MVP, esquel@sommarskog.se

Books Online for SQL Server 2005 at
http://www.microsoft.com/technet/prodtechnol/sql/2005/downloads/books.mspx
Books Online for SQL Server 2000 at
http://www.microsoft.com/sql/prodinfo/previousversions/books.mspx

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация