1、首先使用Navicat连接Oracle数据库
2、使用Navicat创建数据表
数据表
cron_id
cron
1
0/1 * * * * ?
2
0/5 * * * * ?
查询语句
select "cron" from "cron" where "cron_id"=1
3、IDEA连接Oracle数据库
1、导入依赖
com.oracle.ojdbc
ojdbc8
runtime
org.mybatis.spring.boot
mybatis-spring-boot-starter
2.1.0
2、连接配置
3、添加配置文件
application.properties
spring.datasource.driver-class-name=oracle.jdbc.driver.OracleDriver
spring.datasource.url= jdbc:oracle:thin:@localhost:1521:MLDN
spring.datasource.password=zhu
spring.datasource.username=zhu
4、连接成功
原文:https://www.cnblogs.com/zhuchengbo/p/12684551.html