Maven installs the Oracle JDBC driver

The Oracle driver needs to be authorized to download, Maven does not provide it, and we need to install it ourselves.

 All officially downloaded drivers are packaged and downloaded (2016.8.10) (why do you need to log in and download again, I suspect that the downloader information will be saved in the Jar package)

            http://pan.baidu.com/s/1bIxxKy

 

 

Driver download address:
			http://www.oracle.com/technetwork/database/features/jdbc/index-091264.html
------------------------------------------------------------------------
Oracle Database 12c Release 1 (12.1.0.2) drivers
     Oracle Database 12.1.0.2 JDBC Driver & UCP Downloads
http://www.oracle.com/technetwork/database/features/jdbc/default-2280470.html

JDBC Thin driver from the Oracle database release
 	ojdbc7.jar  -  Certified with JDK7 and JDK 8
	ojdbc6.jar  -  For use with JDK 6;
	
Universal Connection Pool (UCP) - Universal Connection Pool classes for use with JDK 6 & JDK 7


---------------------------------------------------------------------

Oracle Database 11g Release 2 JDBC Drivers
    Oracle Database 11g Release 2 (11.2.0.4) JDBC Drivers
http://www.oracle.com/technetwork/database/enterprise-edition/jdbc-112010-090769.html

 
JDBC Thin for All Platforms
 	ojdbc5.jar  -  Classes for use with JDK 1.5
	ojdbc6.jar  -  with JDK 8, JDK 7 and JDK 6
	


---------------------------------------------------------------------
Oracle Database 10g Release 2 JDBC Drivers
	Oracle Database 10g Release 2 (10.2.0.5) JDBC Drivers (Unsupported)
	http://www.oracle.com/technetwork/database/enterprise-edition/jdbc-10201-088211.html10g
	
	 	classes12.jar  -    for use with JDK 1.2 and JDK 1.3
		classes14.jar  -    for use with JDK 1.4 and 1.5
		
------------------------------------------------------------

Maven installation: http://blog.csdn.net/chenzenan/article/details/30239041

cmd switches to each individual jar folder and runs the following commands (each folder can only execute one)

mvn install:install-file -DgroupId=com.oracle -DartifactId=ojdbc7 -Dversion=12.1.0.2 -Dpackaging=jar -Dfile=ojdbc7.jar
mvn install:install-file -DgroupId=com.oracle -DartifactId=ojdbc6 -Dversion=12.1.0.2 -Dpackaging=jar -Dfile=ojdbc6.jar
mvn install:install-file -DgroupId=com.oracle -DartifactId=ojdbc6 -Dversion=11.2.0.4 -Dpackaging=jar -Dfile=ojdbc6.jar
mvn install:install-file -DgroupId=com.oracle -DartifactId=ojdbc5 -Dversion=11.2.0.4 -Dpackaging=jar -Dfile=ojdbc5.jar
mvn install:install-file -DgroupId=com.oracle -DartifactId=ojdbc12 -Dversion=10.2.0.5 -Dpackaging=jar -Dfile=classes12.jar
mvn install:install-file -DgroupId=com.oracle -DartifactId=ojdbc14 -Dversion=10.2.0.5 -Dpackaging=jar -Dfile=ojdbc14.jar

 
------------Maven PoM.xml  Oracle 12C------------------------
	<!-- oracle-12c jdbc driver for JDK7&8 -->    
	<dependency>      
		<groupId>com.oracle</groupId>      
		<artifactId>ojdbc7</artifactId>      
		<version>12.1.0.2</version>  
	</dependency>  
	
	<!-- oracle-12c jdbc driver for JDK6 -->    
	<dependency>      
		<groupId>com.oracle</groupId>      
		<artifactId>ojdbc6</artifactId>      
		<version>12.1.0.2</version>  
	</dependency>
  

------------Maven PoM.xml  Oracle 11g------------------------
	<!-- oracle-11g jdbc driver for JDK6&7&8 -->    
	<dependency>      
		<groupId>com.oracle</groupId>      
		<artifactId>ojdbc6</artifactId>      
		<version>11.2.0.4</version>  
	</dependency>  
	
	<!-- oracle-11g jdbc driver for JDK1.5 -->    
	<dependency>      
		<groupId>com.oracle</groupId>      
		<artifactId>ojdbc5</artifactId>      
		<version>11.2.0.4</version>  
	</dependency>
  

------------Maven PoM.xml  Oracle 10g------------------------
	<!-- oracle-10g jdbc driver for JDK 1.2 & 1.3 -->    
	<dependency>      
		<groupId>com.oracle</groupId>      
		<artifactId>ojdbc12</artifactId>      
		<version>10.2.0.5</version>  
	</dependency>  
	
	<!-- oracle-10g jdbc driver for JDK 1.4 & 1.5 -->    
	<dependency>      
		<groupId>com.oracle</groupId>      
		<artifactId>ojdbc14</artifactId>      
		<version>10.2.0.5</version>  
	</dependency>
  
----------------------------------------------------------------------------


another to install

mvn install:install-file -Dfile=D:/spymemcached-2.10.3.jar -DgroupId=net.spy -DartifactId=spymemcached -Dversion=2.10.3 -Dpackaging=jar  
mvn install:install-file -Dfile=D:/spymemcached-2.10.3-sources.jar -DgroupId=net.spy -DartifactId=spymemcached -Dversion=2.10.3 -Dpackaging=jar -Dclassifier=sources  
mvn install:install-file -Dfile=D:/spymemcached-2.10.3-javadoc.jar -DgroupId=net.spy -DartifactId=spymemcached -Dversion=2.10.3 -Dpackaging=jar -Dclassifier=javadoc









 

Guess you like

Origin http://10.200.1.11:23101/article/api/json?id=326667709&siteId=291194637