title: Network error while connecting to sql server
body: <p>I am using sql server 2008 and jtds driver to establish a connection between sql server and the jsp application. I code i used is </p>
  
  <pre><code>  java.sql.SQLException: Network error IOException: Connection refused: connect
       String url= "jdbc:jtds:sqlserver://127.0.0.1/sfts";
  String id= "sfts";
  String pass = "sfts";
  try{
       Class.forName("net.sourceforge.jtds.jdbc.Driver");
       con = java.sql.DriverManager.getConnection(url, id, pass);
      }catch(Exception e){
                  out.println(e);
       }
  </code></pre>
  
  <p>While running this code, it showing error as  </p>
  
  <pre><code>  java.sql.SQLException: Network error IOException: Connection refused: connect
  </code></pre>
  
  <p>TCP/IP was set enabled and port number was set to 1433. But still it is showing this error.. What to do now??</p>