Hi All,
 
 I am facing one prroblem with run the sql scripts using Maven
 I am having Maven2 and oracle 10g in my machine.
 I have developed teh POM.xml as follows:

 <?xml version="1.0" encoding="UTF-8"?>
 <project>
 <modelVersion>4.0.0</modelVersion>
 <groupId>org.myproject.plugins</groupId>
 <artifactId>MavenSQL-plugin</artifactId>
 <version>1.0-SNAPSHOT</version>
 <name>Maven SQL Plugin</name>
  <build>
 <plugins>
   <plugin>
        <groupId>org.codehaus.mojo</groupId>
        <artifactId>sql-maven-plugin</artifactId>
  <version>1.2</version>
        <dependencies>
           <dependency>
    <groupId>ojdbc</groupId>
    <artifactId>ojdbc</artifactId>
    <version>14</version>
   </dependency>
         </dependencies> 
   <!-- common configuration shared by all executions -->
  <configuration>
           <username>test1</username>
           <password>test1</password>
           <driver>oracle.jdbc.driver.OracleDriver</driver>
           <url>jdbc:oracle:thin:@localhost:1521:strng</url>
         </configuration>
       </plugin>
   </plugins>
 </build>
</project>
when i run the following command it is giving me following error:
C:>mvn sql:execute 
Missing:
----------
1) ojdbc:ojdbc:jar:14
  Try downloading the file manually from:
      http://www.oracle.com/technology/software/tech/java/sqlj_jdbc/index.html
  Then, install it using the command:
      mvn install:install-file -DgroupId=ojdbc -DartifactId=ojdbc -Dversion=14 
-Dpackaging=jar -Dfile=/path/to/file
  Alternatively, if you host your own repository you can deploy the file there:
      mvn deploy:deploy-file -DgroupId=ojdbc -DartifactId=ojdbc -Dversion=14 
-Dpackaging=jar -Dfile=/path/to/file -Durl=[url] -DrepositoryId=[id]
  Path to dependency:
        1) org.codehaus.mojo:sql-maven-plugin:maven-plugin:1.2
        2) ojdbc:ojdbc:jar:14
----------
1 required artifact is missing.
for artifact:
  org.codehaus.mojo:sql-maven-plugin:maven-plugin:1.2
from the specified remote repositories:
  codehaus.org (http://snapshots.repository.codehaus.org),
  central (http://repo1.maven.org/maven2)

Could you please let me know, How to run the above maven scripts using cmd and 
solve this problem.
Regards,
Srinivas


      

Reply via email to