0

I am trying to connect my eclipse with xampp's mysql but its not even able to ping mysql. I already added the connector in classpath and also modified the my.ini(config of xampp's mysql) by uncommenting bindaddress="127.0.0.1" I tried with various url to establish jdbc connectivity like "http://localhost/phpmyadmin/login", "root", "" "http://localhost:3306/login", "root", ""

Please help any suggestion will be welcome

Shubham
  • 1
  • 2
  • Possible duplicate of [Connect Java to a MySQL database](http://stackoverflow.com/questions/2839321/connect-java-to-a-mysql-database) – Mark Rotteveel Apr 23 '16 at 08:22

1 Answers1

0

JDBC connection URLs begin with jdbc:, not http:. The basic form is

jdbc:mysql://localhost:3306/mydb

where 3306 is the default listening port for MySQL server, and mydb is the name of the database you want to use.

Gord Thompson
  • 116,920
  • 32
  • 215
  • 418
  • Thanks Gord, its a typo here i was using jdbc inplace of http, but now the problem has solved don't know how but i cleaned and restart the eclipse – Shubham Apr 23 '16 at 13:06