I have a dependency with scope provided in pom.xml file. But m2e give Missing artifact error

<dependency>  
   <groupId>com.oracle</groupId>  
   <artifactId>ojdbc6</artifactId>  
   <version>11.2.0.3</version>  
   <scope>provided</scope>  
</dependency>`

Why is it so ? I have 4 more dependencies with provided scope all are having same error.

有帮助吗?

解决方案

ojdbc6 is not available in maven repository, install it locally. This is required even if with scope provided.

mvn install:install-file -Dfile={Path/to/your/ojdbc.jar} -DgroupId=com.oracle -DartifactId=ojdbc6 -Dversion=11.2.0.3 -Dpackaging=jar

More: How To Add Oracle JDBC Driver In Your Maven Local Repository

其他提示

As MariuszS already mentioned an other alterative would be to use a repository manager and install it there.

许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top