随笔分类 -  ORM相关

摘要:Jpa查询 JpaRepository简单查询 基本查询也分为两种,一种是spring data默认已经实现,一种是根据查询的方法来自动解析成SQL。 预先生成方法 spring data jpa 默认预先生成了一些基本的CURD的方法,例如:增、删、改等等 继承JpaRepository publ 阅读全文 »
posted @ 2021-07-02 00:06 satire 阅读(1301) 评论(1) 推荐(3) 编辑
摘要:Criteria Query 可以看作传统sql的对象化表示。 Criteria 可以由session创建。 Criteria ct= session.createCriteria(TUser.class); 先来一段小Demo: TbItemParamExample example = new T 阅读全文 »
posted @ 2021-06-30 15:42 satire 阅读(7932) 评论(0) 推荐(0) 编辑
摘要:How to Timeout JDBC Queries JDBC queries by default do not have any timeout, which means that a query can block the thread for an unlimited amount tim 阅读全文 »
posted @ 2021-04-15 14:28 satire 阅读(307) 评论(0) 推荐(0) 编辑
摘要:Learn to configure H2 database with Spring boot to create and use an in-memory database in runtime, generally for unit testing or POC purposes. Rememb 阅读全文 »
posted @ 2021-04-01 15:03 satire 阅读(221) 评论(0) 推荐(0) 编辑
摘要:数据库事务(Database Transaction) ,是指作为单个逻辑工作单元执行的一系列操作,要么完全地执行,要么完全地不执行。 事务处理可以确保除非事务性单元内的所有操作都成功完成,否则不会永久更新面向数据的资源。通过将一组相关操作组合为一个要么全部成功要么全部失败的单元,可以简化错误恢复并 阅读全文 »
posted @ 2021-01-27 11:08 satire 阅读(677) 评论(0) 推荐(0) 编辑

点击右上角即可分享
微信分享提示