ClassNotFoundException com.mysql.jdbc.Driver [duplicate]

If you’re facing this problem with Eclipse, I’ve been following many different solutions but the one that worked for me is this:

  1. Right click your project folder and open up Properties.

  2. From the right panel, select Java Build Path then go to Libraries tab.

  3. Select Add External JARs to import the mysql driver.

  4. From the right panel, select Deployment Assembly.

  5. Select Add…, then select Java Build Path Entries and click Next.

  6. You should see the sql driver on the list. Select it and click first.

And that’s it! Try to run it again! Cheers!

Leave a Comment