hi friends
i am connecting to sql server with java through eclipse as IDE.
here's my base connectivity class to sql server
public class BaseDAO {
public Connection getConnection() throws Exception
{
String userName = "aman";
String password = "password";
String url = "jdbc:microsoft:sqlserver://localhost:1433;DatabaseName=amandb";
// step 1
Class.forName("com.microsoft.sqlserver.jdbc.SQLServerDriver").newInstance();
// Step 2
return DriverManager.getConnection(url, userName,password);
}
}
but i use to get error like
No suitable driver found for jdbc:microsoft:sqlserver://localhost:1433;DatabaseName=amandb
can anybody tell, if its error of jar file i added or some code specific error. kindly help if possible to solve the concerned issue
thanx in advance....