Click here to Skip to main content
15,886,664 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi there,

I'm wondering if someone can help!

I am using SQL Server Mangement Studio 2008 to access the Northwind database. What is the Sever name I need to use to access the Northwind database? I get an error message saying "Cannot connect to local" when I click on Connect.

Can you please let me know when I am going wrong?

Thanks in advance.

Awais
Posted
Comments
Member 9839894 16-Feb-13 12:36pm    
Hi,

Thank you for your response.

When I select "Browse for Servers" option; under the "Local Servers" AND Network Servers I don get anything - blank.

With regards to Server name, you mentioned that "your instance will appear there" - is this something I need to setup? If yes, can you please instruct me how to do that ? Do I need to install the Northwind database first to connect to the server?

Regards,

Yes - you are either trying to connect to the database via SQL server when you don't have it installed (and possibly don't need it) or you aren't specifying the server instance correctly.

Since you tagged this SQL-Server I will assume you do want to access the DB via SQL server, so the first thing you need to do is connect to it. If you run SSMS, you will be at the "Connect to Server" dialog. Make sure that the "Server type" is set to "Database Engine" then try to open the "Server name" drop down - with any luck your instance will appear there. If it doesn't (you have no named instances showing) click the "Browse for more" selection and it should open a new dialog to let you find it. If you installed SQL server on your own pc, then it will be a "Local Server", otherwise it will be a "Network Server".
When you have selected the correct server and logged in, you can then attach your database (if it isn't already) via the object explorer - but connect first and worry about that afterwards!
 
Share this answer
 
Is Northwind database even installed?

You DO know that Northwind database is somewhat dated. I suggest you download from the MS site a more current target for SQL Server development samples ... say AdventureWorks.

By the way, your tag is specifically, and solely, "Sql-Server". If you don't generalize and add more peas to the soup, the only answers you'll get here in Q&A are going to be within that narrow "green" scope.

[Edit]
Ok Awais ...
1. Download the Northwind.sql.zip from codeplex -> http://northwinddatabase.codeplex.com/releases/view/71634[^]
2. Unzip the .sql file into a directory on your installation drive.
3. Using SQL Server Management Studio (try to) open the script named "Northwind.sql"
4. Tricky part here ... in one case that "open" will result in a notepad rendition of the file. It's ok. But you want to get that script that you see there printed on the page INTO ssms editor as a viable, encoded .sql script.
Now, you could try, again qualifying the fact that all systems are different, and it might work for you (doesn't for me), opening this unzipped script USING "guess encoding". It will open in ssms .. BUT the code won't be readable by ssms. And by readable I mean executable.
5. The least tricky part (thee/my way). Just open the unzipped Northwind.sql using notepad, Ctrl+A the entire text, Click on the "New Query" button to make a script space in the ssms editor window, and paste this copied text. You'll notice that the code is colorized.
6. Before you "F5" this (entire) viable script, you've got to create the "Northwind" DB on your machine. To do that, in "Object Browser" right click on the "Database" folder (its a treeview) and select "New Database". In the popup fill in the Database name "Northwind" and hit OK.
7. The thought just occured to me that you don't even have an instance of SQL Server running on your machine. In which case before you do any of the above stuff, go to the Microsoft site and download any of the (great, as in robust) SQL Server packages. I recommend SQL Server 2008 R2 64-bit with Advanced Services. There's probably a help file that is a "Book on Line" commonly refered to in lay parlance as "BOL".
8. Good luck.
[End edit]
 
Share this answer
 
v2
Comments
Member 9839894 16-Feb-13 17:58pm    
I have got the latest version of the Northwind database from the MS website. The files are saved on my PC, however, I am having problems with connecting to the server - can you help with that? The server name i am using is called "local" by default ? Is this correct? If not, do you know the correct Server Name I need to use to connect to the Northwind database?
Member 9839894 16-Feb-13 18:02pm    
I cant install it because I am unable to connect to the Northwind server ? Does anyone know the Northwind server name ?
RedDk 16-Feb-13 19:03pm    
Your next step would be to go into "Computer Managment" console and check to see if, under "Services and Applications", "Service", (standard view tab) any instance of "SQL Server (xxxxxxx)" exists. If no I've gotta ask: how are you NOT seeing any instance in the splash log-onto popup? Visual Studio?

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900