12

I'm trying to install some .Net eCommerce projects on my local machine (windows Vista) with Webmatrix. Some of them ask for a Database administrator username and password, but I have no idea what those are.

Can anybody help me on this. See image which is a screenshot of the installation process.

Screenshot of installation process

Daniel A. White
  • 187,200
  • 47
  • 362
  • 445
Daniël Tulp
  • 1,745
  • 2
  • 22
  • 51

4 Answers4

17

In your client (SQL Server Management Studio) you have to:

  1. change password for login user "sa"
  2. enable login for user "sa"
  3. ensure SQL Server authentication is enabled

1. change password for login user "sa"

Security > Logins > sa (right-click) > Properties > General > Password and Confirm password

2. enable login for user "sa"

Security > Logins > sa (right-click) > Properties > Status > Login, click in Enabled

3. ensure SQL Server authentication is enabled

Right click on server > Properties > Security > Server authentication, click in SQL Server and Windows Authentication mode

rogeriopradoj
  • 400
  • 3
  • 9
  • 3
    4. You may need to restart the SQL Server service. Right Click on Server name > Restart. – Adil H. Raza Mar 07 '20 at 17:17
  • Could it be that step 1 requires that the user that connected to the database has sufficient permissions to change the password of sa? I got `Alter failed for Login 'sa'. (Microsoft.SqlServer.Smo)` and `Cannot alter the login 'sa', because it does not exist or you do not have permission. (Microsoft SQL Server, Error: 15151)` See the question [sql server 2012: cannot alter the login sa](https://stackoverflow.com/questions/17788853/) – surfmuggle Feb 02 '22 at 08:13
16

By Default the SQLEXPRESS installation uses Windows Authentication. in the management studio on the security-tab of the server properties you can select "SQL Server and Windows Authentication" ONLY THEN The 'sa' account is accepted. You probably have to set/reset the password for this account if you can't remember you entered it.

Luuk Krijnen
  • 1,180
  • 3
  • 14
  • 37
  • I had to uninstall Management studio epxress 2005 and install 2008 (pff took forever to install) and then was able to change the password with the Management studio – Daniël Tulp May 30 '12 at 13:41
  • 2
    I still wasn't able to log in with the sa account, then I tried to logon to the Manager studio with the sa account and it said it was disabled (huh?), I was able to enable it via the properties of the sa account and then the Status tab – Daniël Tulp May 31 '12 at 07:33
  • you will need to log in to management studio using windows authentication first if SQL auth is not enabled – ruffrey Apr 11 '13 at 16:01
4

I had the same problem and i performed the below steps to resolve the issue:

  1. Open Sql Server Management Studio as Administartor

  2. Login to .\SQLEXPRESS using Windows Authentication

  3. Go to Security Tab -- > Logins --> Change the "sa" password and Press Ok

  4. Use the newly created Password in WebMatrix and you should be all Set.

Ravi Reddy
  • 86
  • 2
0

Since SQL 2005 the Express edition is installed with windows authentication. In the configuration (management studio, connect to the server and choose database properties) you can activate sql internal authentification then (default deactivated, user sa without password).

So if you can't connect it you might have to activate it and set a password for the user sa then.

YvesR
  • 5,922
  • 6
  • 43
  • 70