Programming Tutorials

Comment on Tutorial - Using JDBC to connect to MySQL from Java Program By Rajan



Comment Added by : Partha

Comment Added at : 2009-11-28 11:32:53

Comment on Tutorial : Using JDBC to connect to MySQL from Java Program By Rajan
It seems like your getConnection doesnt recognize the credentials you pass. Can you try like this?

String url = "jdbc:mysql://localhost:3306/details";
Class.forName("com.mysql.jdbc.Driver");
Connection con = DriverManager.getConnection (url, "root", "root");


View Tutorial