NetBeans Forums
| View previous topic :: View next topic |
| Author |
Message |
sijran
Joined: 10 Aug 2010 Posts: 2
|
Posted: Tue Aug 10, 2010 2:21 am Post subject: cannot connect to mySql database |
|
|
I've given
Class.forName("com.mysql.jdbc.Driver");
String conURL="jdbc:mysql://localhost:3306/practice";
con=DriverManager.getConnection(conURL);
in a class which is accesing my database created in MySql using phpMyadmin. I've also downloaded \mysql-connector-java-5.1.13\mysql-connector-java-5.1.13-bin\com\mysql\jdbc file of mysql but do not know how to use of it . Please somebody help me. |
|
| Back to top |
|
 |
julsorio
Joined: 05 Jun 2009 Posts: 168 Location: Bogota, Colombia, South America
|
Posted: Tue Aug 10, 2010 4:53 pm Post subject: Re: cannot connect to mySql database |
|
|
con = DriverManager.getConnection(conUrl, "user", "password");
On 9 August 2010 21:21, sijran <address-removed ([email]address-removed[/email])> wrote:
| Quote: | I've given
Class.forName("com.mysql.jdbc.Driver");
|
|
| Back to top |
|
 |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum You can attach files in this forum You can download files in this forum
|
|
|