1
votes

Error while using SQL Server Management Studio 17

TITLE: Connect to Server

Cannot connect to (local).

ADDITIONAL INFORMATION: A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections. (provider: Named Pipes Provider, error: 40 - Could not open a connection to SQL Server) (Microsoft SQL Server, Error: 2) > The system cannot find the file specified

2
Have you ever connected before? Do you have a SQL Server installed?Nick.McDermaid

2 Answers

1
votes

The reason may SQL server Services is not runing in your PC.

Go to Sql Server Configuration manager Then select SQL server Services in left side and then select SQL SERVER (MSSQLSERVER) in right side. If it is not ruining you cab run it.

It works for me.

0
votes

Looks like your server and SQL Server Management Studio are on different computers. You need to connect remotely to the server, then start management studio remotely. Then right click on server instance, and then check option to allow remote connections:

enter image description here

Also, if youre using sql type of login, you need to allow this: enter image description here

Another potential reason - firewall. Please allow standard SQL Server ports on server computer, and then check client computer firewall

And lastly - please check SQL Server computer, or server allows tcp/ip connections