Community
cancel
Showing results for 
Search instead for 
Did you mean: 
TTony5
New Contributor I
1,306 Views

ClassNotFoundException whe using mySQL connector on Eclipse IoT

Jump to solution

Hi,

I am trying to connect an Intel Edison to a mySQL database in Java using Eclipse IoT dev. I added the mySQL connector to the classpath but I keep getting a ClassNotFound Exception.

I do not understand what is hapenning or even if it is possible to use this library on the Intel Edison.

Class.forName cannot be foundjava.lang.ClassNotFoundException: com.mysql.jdbc.Driver

Please, any ideas about this?


Accepted Solutions
Pedro_M_Intel
Employee
51 Views

Hello TonyMontes,

I personally have never tried to add mySQL to Eclipse but I found http://www.ccs.neu.edu/home/kathleen/classes/cs3200/JDBCtutorial.pdf this guide, in step 2 they install the Connector/J driver so their program can connect to MySQL, you could check it to see if it helps you. This https://examples.javacodegeeks.com/core-java/mysql-connector-for-java-how-to-install-in-eclipse-and-... other guide looks even more complete, it might be worth looking at it as well.

Let me know if those documents help you install mySQL connector.

Peter.

View solution in original post

3 Replies
Pedro_M_Intel
Employee
52 Views

Hello TonyMontes,

I personally have never tried to add mySQL to Eclipse but I found http://www.ccs.neu.edu/home/kathleen/classes/cs3200/JDBCtutorial.pdf this guide, in step 2 they install the Connector/J driver so their program can connect to MySQL, you could check it to see if it helps you. This https://examples.javacodegeeks.com/core-java/mysql-connector-for-java-how-to-install-in-eclipse-and-... other guide looks even more complete, it might be worth looking at it as well.

Let me know if those documents help you install mySQL connector.

Peter.

View solution in original post

TTony5
New Contributor I
51 Views

Thanks Peter,

I forgot to mention that I already have the Connector installed and it works fine when creating a regular Java project, however it throws the ClassNotFoundException when running the code on a Java Intel IoT project.

 

 

Pedro_M_Intel
Employee
51 Views

I see, can you share your code or an example code? I would like to test it to see if I can replicate the issue.

Peter.