0
Q:
Creating a user in SQL Server 2000
How do I create a user in SQL Server 2000?
ASKED: Jul 28 2008  7:12 PM GMT
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
0
47070 pts.
0
A:
 RATE THIS ANSWER
-1
Click to Vote:
  •   0
  •  -1
  • AddThis Social Bookmark Button
Logins are created using the sp_addlogin stored procedure in the master database.

exec sp_addlogin @loginame='NewLoginName',
@passwd='The Password',
@defdb='Default Database Name', --Optional
@deflanguage='Language' --Optional


To grant a user rights into the database you then need to go into that database and use the sp_adduser command.

exec sp_adduser @loginame='NewLoginName',
@name_in_db='NewUserName',
@grpname='A database Group you want to put the user into' --optional


Be sure to read up on the differences between Logins and Users.
Last Answered: Jul 28 2008  8:38 PM GMT by Mrdenny   47070 pts.
Latest Contributors: Flame   14495 pts.
0
0
Discuss This Answer:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _



_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

Mrdenny   47070 pts.  |   Jul 28 2008  8:39PM GMT

Check out my SQL Server blog “SQL Server with Mr Denny” for more SQL Server information.

 
0