title: Can't connect to SQL Server 2005
body: <p>I've installed SQL Server 2005 on my machine and now I'm trying to connect to it via SQuirrel SQL, but I am unfortunately running into problems.</p>
  
  <p>When installing SQL Server 2005 I chose mixed mode for authentication and I've set up a new user account with which I'm trying to connect. I've also installed the Microsoft SQL Server JDBC Driver and I have successfully used SQuirrel SQL to connect to a remote server before. </p>
  
  <p>Currently I'm trying to connect to my database by specifying </p>
  
  <pre><code>jdbc:sqlserver://localhost:1433
  </code></pre>
  
  <p>for the URL and selecting Microsoft SQL Server JDBC Driver.</p>
  
  <p>After entering my username and password I'm getting the following error:</p>
  
  <blockquote>
    <p>test: The TCP/IP connection to the host  has failed. 
    java.net.ConnectException: Connection refused: connect</p>
  </blockquote>
  
  <p>with the following stack trace:</p>
  
  <pre><code>com.microsoft.sqlserver.jdbc.SQLServerException: The TCP/IP connection to the host  has failed. java.net.ConnectException: Connection refused: connect
      at com.microsoft.sqlserver.jdbc.SQLServerException.makeFromDriverError(Unknown Source)
      at com.microsoft.sqlserver.jdbc.SQLServerConnection.connect(Unknown Source)
      at com.microsoft.sqlserver.jdbc.SQLServerDriver.connect(Unknown Source)
      at net.sourceforge.squirrel_sql.fw.sql.SQLDriverManager.getConnection(SQLDriverManager.java:133)
      at net.sourceforge.squirrel_sql.client.mainframe.action.OpenConnectionCommand.execute(OpenConnectionCommand.java:97)
      at net.sourceforge.squirrel_sql.client.mainframe.action.ConnectToAliasCommand$SheetHandler.run(ConnectToAliasCommand.java:279)
      at net.sourceforge.squirrel_sql.fw.util.TaskExecuter.run(TaskExecuter.java:82)
      at java.lang.Thread.run(Unknown Source)
  </code></pre>
  
  <p>One last thing, I've checked to make sure TCP/IP connections and named pipes are enabled in the SQL Server Configuration Manager.</p>
  
  <p>If anyone has any thoughts on my problem I would be very grateful to hear them.</p>