How do I connect to SQL Server using C#?

How do i connect to server on Microsoft SQL Server 2005?

  • I have just installed Microsoft SQL Server 2005. When I start the Server Management Studio, it displays a "Connect to Server" dialog box. I have tried my best to connect to the serevr, but i dont know which server the programming is asking to connect to. I am assuming it's a local server that is set up on my machine since the setup required me to install Windows IIS, but i have no idea how to connect to it. I tried using all the options available at the "Connect to Server" dialog, but i am still unable to connect to a server. What should I do? I am frustrated and i need to use this software pronto, since i have assignments and deadlines to complete for my Enterprise Computing course.

  • Answer:

    When you installed SQL 2005, did you make sure to set up the local database? When installing, you can install the client tools only... or server and client. You want server and client. In doing so, it will create a local DB for you. When you open up the SQL Express window, you can then connect to the local DB.

Psybuck at Yahoo! Answers Visit the source

Was this solution helpful to you?

Related Q & A:

Just Added Q & A:

Find solution

For every problem there is a solution! Proved by Solucija.

  • Got an issue and looking for advice?

  • Ask Solucija to search every corner of the Web for help.

  • Get workable solutions and helpful tips in a moment.

Just ask Solucija about an issue you face and immediately get a list of ready solutions, answers and tips from other Internet users. We always provide the most suitable and complete answer to your question at the top, along with a few good alternatives below.