常用数据库JDBC URL格式

常用数据库JDBC URL格式


Oracle
Oracle Thin JDBC Driver
驱动程序包名:ojdbc14.jar
驱动程序类名: oracle.jdbc.driver.OracleDriver
JDBC URL: 
jdbc:oracle:thin:@//<host>:<port>/ServiceName

jdbc:oracle:thin:@<host>:<port>:<SID>


IBM DB2
IBM DB2 Universal Driver Type 4
驱动程序包名:db2jcc.jar db2jcc_license_cu.jar
驱动程序类名: com.ibm.db2.jcc.DB2Driver
JDBC URL: jdbc:db2://<host>[:<port>]/<database_name>


IBM DB2 Universal Driver Type 2
驱动程序包名:db2jcc.jar db2jcc_license_cu.jar
驱动程序类名: com.ibm.db2.jcc.DB2Driver
JDBC URL: jdbc:db2:<database_name>


MySQL
MySQL Connector/J Driver
驱动程序包名:mysql-connector-java-x.x.xx-bin.jar
驱动程序类名: com.mysql.jdbc.Driver
JDBC URL: jdbc:mysql://<host>:<port>/<database_name>
默认端口3306,如果服务器使用默认端口则port可以省略
MySQL Connector/J Driver 允许在URL中添加额外的连接属性jdbc:mysql://<host>:<port>/<database_name>?property1=value1&property2=value2


Informix
Informix JDBC Driver
驱动程序包名:ifxjdbc.jar
驱动程序类名: com.informix.jdbc.IfxDriver
JDBC URL: jdbc:informix-sqli://{<ip-address>|<host-name>}:<port-number>[/<dbname>]: INFORMIXSERVER=<server-name>


Sybase
Sybase Adaptive Server Enterprise JDBC Driver
驱动程序包名:jconn2.jar 或jconn3.jar
驱动程序类名: com.sybase.jdbc2.jdbc.SybDriver (com.sybase.jdbc3.jdbc.SybDriver)
JDBC URL: jdbc:sybase:Tds:<host>:<port>默认端口5000


Sybase Adaptive Server Anywhere or Sybase IQ JDBC Driver
驱动程序包名:jconn2.jar 或jconn3.jar
驱动程序类名: com.sybase.jdbc2.jdbc.SybDriver (com.sybase.jdbc3.jdbc.SybDriver)
JDBC URL: jdbc:sybase:Tds:<host>:<port>?ServiceName=<database_name>
默认端口2638
相关推荐
©️2020 CSDN 皮肤主题: 大白 设计师:CSDN官方博客 返回首页