spring-boot-starter-jdbc依赖
时间: 2023-09-03 17:10:50 浏览: 113
log4jdbc-spring-boot-starter:将Log4jdbc与Spring Boot结合使用的启动器
spring-boot-starter-jdbc是一个Spring Boot的起步依赖,用于提供自动配置的数据访问基础设施。一旦将spring-boot-starter-jdbc添加为应用的依赖,它会直接或间接依赖spring-jdbc,从而触发数据访问相关的自动配置行为。要使用spring-boot-starter-jdbc,你需要在项目的pom.xml文件中引入以下Maven依赖包:
```
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-jdbc</artifactId>
</dependency>
<dependency>
<groupId>mysql</groupId>
<artifactId>mysql-connector-java</artifactId>
</dependency>
```这样就可以使用Spring JDBC来访问MySQL数据库了。请注意,这只是一个简单的示例,如果你想更深入地学习Spring JDBC的使用,建议参考Spring JDBC教程。<span class="em">1</span><span class="em">2</span><span class="em">3</span>
#### 引用[.reference_title]
- *1* [springboot之spring-boot-starter-jdbc](https://blog.csdn.net/qq_25453181/article/details/106041696)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v93^chatsearchT3_2"}}] [.reference_item style="max-width: 50%"]
- *2* *3* [Springboot框架整合Spring JDBC操作数据](https://blog.csdn.net/javayoungcoolboy/article/details/131065446)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v93^chatsearchT3_2"}}] [.reference_item style="max-width: 50%"]
[ .reference_list ]
阅读全文