Home > Net >  Java build path problems?
Java build path problems?

Time:10-08

I want to connect to mysql using jdbc in my spring project. I havee added the mysql-connector dependency to the pom.xml project file:

    <dependency>
        <groupId>mysql</groupId>
        <artifactId>mysql-connector-java</artifactId>
        <version>8.0.26</version>
    </dependency>

This is throwing an error:

The container 'Maven Dependencies' references non existing library 'C:\Users\User\.m2\repository\mysql\mysql-connector-java\8.0.26\mysql-connector-java-8.0.26.jar'

Once I remove this, everything works fine. Same issue with c3p0 dependency. Please help.

CodePudding user response:

1.Go to your project path and run maven install.wait until the installation process is completed successfully. 2.Then Run maven update. 3.Try to clean your project and do maven build.

  • Related