SQLServerNewBie2
SQLServerNewBie2

Reputation: 35

How will I know the sql server database name to connect from SSMS

Installed SSMS 2017 version. When I launch it first time, it asks for server name to connect to. I installed SQL server 2014 already. But I don't know the name of the server. I tried giving server name as "local". But it wouldn't accept. It says "Cannot connect to to local" Error: 53

Since I installed SQL server on my local machine, "local" should be acceptable name as a server to connect to from SSMS.

server name?

Upvotes: 0

Views: 149

Answers (5)

Dinesh vishe
Dinesh vishe

Reputation: 3598

You need connect using . only.

enter image description here

connect Local instance using .

enter image description here

enter image description here

Upvotes: 0

ahmed abdelqader
ahmed abdelqader

Reputation: 3560

You can use (.), or local or localhost.

If you used named instance, follow the next:-

Use Browse for more, for getting the accurate server name as next screen shots;-

enter image description here

and under Database Engine, you will get the accurate server name

enter image description here

Upvotes: 2

StrayCatDBA
StrayCatDBA

Reputation: 2880

.

localhost

127.0.0.1

Any of these will connect to sql server running on your local machine.

If you installed sql as a named instance, then .\myinstance, localhost\myinstance, etc

Upvotes: 2

JavanPoirier
JavanPoirier

Reputation: 442

It should be localhost, just setup my SQL server last month and had to find this information aswell.

Upvotes: 0

Derviş Kayımbaşıoğlu
Derviş Kayımbaşıoğlu

Reputation: 30545

If you have Db connection you can use this command

select @@servername + '\' + @@servicename

you can also check SQL Server Configuration Manager.

In Configuration Manager you need to find SQL Server Service. When you Double click the SQL Service and navigate through Service Tab, you need to see SQL Server Name

Upvotes: 0

Related Questions