1

I'm on Windows 7 and using free version of SQL Server Management Studio. I try connecting to DB server for the first time. I run the program as administrator.

I go to Connect > Database Engine and get a prompt.

Server name: (local)
Authentication: Windows Authentication
User name (greyed out): PC\ABC
Password (greyed out): 

Click Connect and I get:

Cannot connect to (local). Additional information: A network-related or instance-specific error occurred while while establishing a connection to SQL Server.

I'm reading MSDN for the past hour which is of course very frustrating and it makes me want to pull my hair out.

2
  • Have you installed a local SQL Server; or are you trying to connect to a remote one. If local; check services to see if its running.
    – u07ch
    Dec 10, 2010 at 15:30
  • 1
    Please move this question to superuser.com. Do you actually have a SQL Server installed? If so, which one, with which setup? Don't amend the question here, ask it with these additional details on superuser.
    – TToni
    Dec 10, 2010 at 15:32

4 Answers 4

2

to prevent further loss of hair: when you use the free Sql server, called SqlServer Express, the server field needs to be this:

.\SqlExpress

the . is shorthand for local, and the \SqlExpress is the instance name. Bit of an advanced topic, you can run mulitiple SqlServers each having their own name.

more info: http://social.msdn.microsoft.com/forums/en-US/sqldataaccess/thread/e791233e-f805-48b9-82cb-c19da03fbe61/

Good luck with Sql!

1
  • Wow, managed finally thanks to you and JNK. Really this server name would be additional hair loss.
    – Murgh
    Dec 10, 2010 at 16:24
1

If you are running the free SQL Management Studio then you are running SQL Management Studio Express. Then are you also running the free version of SqlServer, SqlExpress?

If so, to connect to SqlExpress on your local machine from ssms express, you need to enter the server name as follows: .\sqlexpress .

0

Did you install SQL Server first?

SQL Server is what actually runs the database.

SQL Server Management Studio connects to an instance of SQL Server. If you dont have the server there's nothing to manage.

Here is a link to the install page from Microsoft.

0
0

Have you got a SQL Server installed locally? That's what having (local) in the Server Name field means - try to connect to the local SQL server.

If not, you need to put in the name of an existing SQL Server.

SQL Server Management Studio is a tool to connect to and manage SQL Server instances, it is not the SQL Server itself.

You must log in to answer this question.