Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Missing artifact com.oracle:ojdbc7 in eclipse

I have imported a Maven Project in Eclipse (EE Developer) and I have in my pom.xml file the following error, “Missing artifact com.oracle:ojdbc7:jar:12.1.0.2″ in this code:

<dependency>
    <groupId>com.oracle</groupId>
    <artifactId>ojdbc7</artifactId>
    <version>12.1.0.2</version>
</dependency>

I have done so by downloading the ojdbc7.jar and run this command:

mvn install:install-file -Dfile=/Path-to-jar/ojdbc7.jar
-DgroupId=com.oracle 
-DartifactId=ojdbc7 
-Dversion=12.1.0.2 
-Dpackaging=jar 
-DgeneratePom=true

After that, I got as an output BUILD SUCCESS, and if I go to the .m2 folder I see in the com->oracle->ojdbc7 two files called “ojdbc7-12.1.0.1.jar.lastUpdated” and “ojdbc7-12.1.0.1.pom.lastUpdated” but still Eclipse brings me the code into the pom.xml file as an error?!?!?! Can some one help?

like image 238
Masih Avatar asked Aug 13 '15 23:08

Masih


People also ask

Where is ojdbc7 jar located?

You will get those jars when installing the Oracle Client, the ojdbcX. jar files appear in ORACLE_HOME/jdbc/lib.


1 Answers

This artifact version (12.1.0.2) has been removed to an another dependency.

See: https://mvnrepository.com/artifact/com.oracle/ojdbc7

Try to change the new dependency:

<dependency>
    <groupId>com.oracle.database.jdbc</groupId>
    <artifactId>ojdbc8</artifactId>
    <version>12.2.0.1</version>
</dependency>
like image 54
Ramzi Kileni Jrad Avatar answered Sep 28 '22 01:09

Ramzi Kileni Jrad