spring-data-jpa官方使用说明文档:https://docs.spring.io/spring-data/jpa/docs/current/reference/html/

 spring-data-jpa的使用说明:https://www.cnblogs.com/WangJinYang/p/4257383.html

spring-data-jpa API地址:https://docs.spring.io/spring-data/data-jpa/docs/current/api/

参考地址:http://blog.didispace.com/springbootdata2/

 ===============================================================================================

spring boot搭建项目后,想要数据进行持久化操作,更进一步的完善项目的话,就要使用到一个具体的ORM了。而spring boot中完美的支持了spring-data-jpa。

这一篇就使用spring-data-jpa进行入门的数据持久化处理

===============================================================================================

本篇数据库使用mysql,所以pom加入依赖需要两个

<!--jpa  hibernate-->
        <dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-starter-data-jpa</artifactId>
        </dependency>
        <!--mysql连接架包-->
        <dependency>
            <groupId>mysql</groupId>
            <artifactId>mysql-connector-java</artifactId>
        </dependency>
View Code

相关文章: