oracle、mysql、达梦(DM)、人大金仓(kingbase)的jdbc.properties文件配置
2023-12-28 10:59:15
文章目录
oracle数据库连接
jdbc.properties
#db.url = jdbc:oracle:thin:@(DESCRIPTION =(ADDRESS_LIST = (ADDRESS = (PROTOCOL = TCP)(HOST = 10.1.187.36)(PORT = 1521)) (ADDRESS = (PROTOCOL = TCP)(HOST = 10.1.187.44)(PORT = 1521)))(CONNECT_DATA = (SERVER = DEDICATED) (SERVICE_NAME = ddxt4)))
#db.username = test
#db.password = test
#db.driver = oracle.jdbc.driver.OracleDriver
#db.url = jdbc:oracle:thin:@127.0.0.1:1521:orcl
#db.dialect = oracle
#db.validationQuery = select 1 from dual
pom
<dependency>
<groupId>com.oracle</groupId>
<artifactId>ojdbc14</artifactId>
<scope>system</scope>
<systemPath>${project.basedir}/src/lib/ojdbc14-10.2.0.5.0.jar</systemPath>
</dependency>
mysql
jdbc.properties
#db.username = test
#db.password = test
#db.driver = com.mysql.jdbc.Driver
#db.url = jdbc:mysql://127.0.0.1:3306/wms?useUnicode=true&characterEncoding=UTF-8&allowMultiQueries=true&autoReconnect=true&useSSL=false
#db.dialect = mysql
#db.validationQuery = select 1
pom
<dependency>
<groupId>mysql</groupId>
<artifactId>mysql-connector-java</artifactId>
<version>5.1.49</version>
</dependency>
达梦(DM)
jdbc.properties
#集群式部署
#db.url = jdbc:dm://AA?AA=(127.0.0.1:5236,127.0.0.1:5236,127.0.0.1:5236)&schema=JWCMS&serverTimezone=UTC&LOGIN_NODE=(1)
db.username = test
db.password = test
db.driver = dm.jdbc.driver.DmDriver
db.url = jdbc:dm://127.0.0.1:5236
db.dialect = oracle
db.validationQuery = select 1 from dual
pom
<dependency>
<groupId>com.dameng</groupId>
<artifactId>DmJdbcDriver18</artifactId>
<version>8.1.1.193</version>
</dependency>
人大金仓(kingbase)
jdbc.properties
#db.username = test
#db.password = test
#db.driver = com.kingbase8.Driver
#db.url = jdbc:kingbase8://127.0.0.1:54321/jwcms
#db.dialect = oracle
#db.validationQuery = select 1 from dual
pom
<dependency>
<groupId>cn.com.kingbase</groupId>
<artifactId>kingbase8</artifactId>
<version>8.6.0</version>
</dependency>
文章来源:https://blog.csdn.net/qq_20025777/article/details/135240647
本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。 如若内容造成侵权/违法违规/事实不符,请联系我的编程经验分享网邮箱:veading@qq.com进行投诉反馈,一经查实,立即删除!
本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。 如若内容造成侵权/违法违规/事实不符,请联系我的编程经验分享网邮箱:veading@qq.com进行投诉反馈,一经查实,立即删除!