Announcement Announcement Module
Collapse
No announcement yet.
Need help Oracle Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • Need help Oracle

    I am not an expert in Spring and roo but things have been going pretty well until I tried to connect to an Oracle Database (I made my first tries with PostGres).

    I must admit that I feel lost and confused because I tried the various steps and advices many times without beeing able to be successfull.

    The message is always the same :
    "The ORACLE JDBC driver is not available in public maven repositories. Please adjust the pom.xml dependency to suit your needs
    Please update your database details in src/main/resources/META-INF/spring/database.properties."

    Let me tell you how I proceed :

    0- Create of roo project from without STS
    1- Downloaded the ojdbc-14.jar from Oracle website
    2 -Run the following command :
    mvn install:install-file -Dfile=/home/user/Documents/Libs/ojdbc14.jar -DgroupId=com.oracle -DartifactId=ojdbc14 -Dversion=10.2.0.2 -Dpackaging=jar
    3- Check in my m2 local repository, I have :
    /home/user/.m2/repository/ojdbc/ojdbc/14/ojdbc-14.jar
    4- Run the roo command :
    persistence setup --provider HIBERNATE --database ORACLE --hostName host.name.fr --databaseName mydatabase --userName user --password password

    What can possibly be wrong ?

    I have check the pom.xml and the database.properties and everthing seems ok.

    I really need your help.

  • #2
    What does your pom.xml look like for the Oracle dependency?

    Comment


    • #3
      The pom looks like :

      <dependency>
      <groupId>com.oracle</groupId>
      <artifactId>ojdbc14</artifactId>
      <version>10.2.0.2</version>
      </dependency>

      Comment


      • #4
        I find the following seems to work for me:

        Install the Oracle Jar into my local Maven:

        Code:
        mvn install:install-file -DgroupId=com.oracle -DartifactId=oracle -Dversion=10.2.0.2 -Dpackaging=jar -Dfile=ojdbc14.jar
        Then add the following dependency into my pom.xml

        Code:
        <dependency>
            <groupId>com.oracle</groupId>
            <artifactId>oracle</artifactId>
            <version>10.2.0.2</version>
        </dependency>

        Comment


        • #5
          This is with Roo 1.1.3 (from the command line rather than from the console in STS) and the Oracle 10 drivers from OTN btw.

          Comment

          Working...
          X