35

While trying to connect to SQL Server 2005 Standard Edition through SQL Server Management Studio 2005 I get the following error:

screen shoot of error is given bellow

I put all my effort to solve this problem but there is no solution. On stack overflow in the following post I found this screen shot: solution of screen shot

When I see my connect to server dialog box I find the difference like

my connect to server dialog box

What is the problem?

This SQL server runs on a single machine, not on a cluster or on a client server.

user4157124
  • 2,809
  • 13
  • 27
  • 42
Waleed Ehsan
  • 365
  • 1
  • 3
  • 8

13 Answers13

51

enter image description here

Go to services (services.msc) and restart the services in the image and then try to connect.

  • trying this but fail then restart machine but fail and even uninssall and then install again fail seeing this error 26 error – Waleed Ehsan Mar 11 '13 at 07:37
36

If you have Microsoft Windows 10:

  1. Type Control Panel on Cortana search bar (which is says by default 'Type here to search'). Or click on Windows icon and type Control Panel
  2. Click on Administrative Tools
  3. Then double click on Services
  4. Scroll down and look for: SQL Server (SQLEXPRESS), after that right click
  5. And then in the pop out windows click on Start

Now you should be able to connect to your pc-name\SQLEXPRESS

S. Mayol
  • 2,565
  • 2
  • 27
  • 34
  • Run the Computer Management applet from Control Panel→Administrative Tools→Computer Management, where you should find the configuration manager installed. – live-love Feb 07 '18 at 22:10
7

When you get this error.

Follow these steps then you solve your problem

  1. Open command prompt by pressing (window + r) keys or Click on windows Button and Type Run then type services.msc and click OK or press Enter key.

2.Find SQL Server (SQLEXPRESS).

3.Now see left upper side and click start.

4.If Service show error then right click on SQL Express and then click on Properties.

5.Then click on Logon Tab.

6.Enter Username and Password of Windows Authentication

7.Then Start your Service

8.Problem will be solve and run your query

7

Use (LocalDB)\MSSQLLocalDB as the server name

Ramanujam Allam
  • 1,300
  • 12
  • 11
5

Follow these steps then you solve your problem 100%.

  1. When you get this error then close everything(Microsoft SQL Server Managment):

error

  1. Then open command prompt by pressing (window + r) keys and type services.msc and click OK or press Enter key.

  2. And search **SQL Server (SQLEXPRESS) as I show in the image.

enter image description here

  1. Now see left upper side and click start.

  2. If you open Microsoft SQL Server Management then you not get any type error.

Enjoy!!!

Milo
  • 3,365
  • 9
  • 30
  • 44
UTKARSH
  • 111
  • 2
  • 2
3

I'm Running Windows 10 and this worked for me:

  1. Open services by searching in the toolbar for Services.
  2. Right click SQL Server (SQLEXPESS)
  3. Go To Properties - Log On
  4. Check Local System Account & Allow service to interact with desktop.
  5. Apply and restart service.
  6. I was then able to connect
3

Initialize the SQL Server Browser Service.

orangething
  • 708
  • 5
  • 16
Luis Mata
  • 73
  • 6
1

try using IP instead of pc name. If the ip working, then it might be the name pipe is not enable. If it;s still not working then the login using windows might be disabled.

1

I had this problem. So I put like this: PC-NAME\SQLSERVER Since the SQLSERVER the instance name that was set at installation.

Authentication: Windows Authentication

Connects !!!

0

go to services and start the ones related to SQL

ady
  • 19
  • 1
0

My issue occurs when I add a PC to a domain. Restarting the service, making sure it's running, that it has the correct credentials to run, etc, as in other answers doesn't work. I don't know exactly what the problem is, but I can't even log in with the local user anymore to give the domain user access. Here's the steps that work for me:

In SSMS

  • View > Registered Servers
  • Database Engine > Local Server Groups > right-click pcname\sqlexpress
  • Delete > Yes
  • Right-click Local Server Groups > Tasks > Register Local Servers
  • It confirms that it re-registered. pcname\sqlexpress reappears.

I'm then able to log in with the local windows auth'd user again, my databases are all there and everything. I then go about my business adding the domain user to Security > Logins.

0

In my case, I was copying and pasting the server name from appsettings.json as;

DESKTOP-IVQP9DJ\\SQLEXPRESS.

So the problem was that there were two slashes in the server name which was causing the issue for me. If you are using .net core and copying/pasting server name like me make sure to use only one slash as:

DESKTOP-IVQP9DJ\SQLEXPRESS

Zeeshan Ahmad Khalil
  • 793
  • 1
  • 12
  • 29
0

If you already did that Then just restart the service :

  1. start menu
  2. Microsoft SQL Server 20xx
  3. Sql Server 20xx Configuration Manager
  4. SQL Server Service (at left tree)
  5. SQL Server (SQLEXPRESS) (at right region)
  6. right click -> restart
shdr
  • 868
  • 10
  • 25