MyBatis-Flex v1.7.3 released, new Delete multi-table association deletion

MyBatis-Flex: An elegant MyBatis enhancement framework

feature

1. Very lightweight

The entire MyBatis-Flex framework only relies on MyBatis and has no other third-party dependencies.

2. Only enhance

MyBatis-Flex supports CRUD, paging queries, multi-table queries, and batch operations without losing any of MyBatis' original functions.

3. High performance

MyBatis-Flex adopts a unique technical architecture. Compared with many similar frameworks, MyBatis-Flex's performance in terms of addition, deletion, modification, and query is 5 to 10 times or more higher than that of many similar frameworks.

4. More flexible

MyBatis-Flex supports multiple primary keys, multi-table queries, logical deletions, optimistic locking, data desensitization, data encryption, multiple data sources, sub-databases and sub-tables, field permissions, field encryption, multi-tenants, transaction management, SQL audit... Etc., etc. All this, free and flexible.

In MyBatis-Flex v1.7.3, new functions related to multi-table association deletion are added, such as:

QueryWrapper qw = QueryWrapper.create()
.from(ACCOUNT).leftJoin(ARTICLE).on(ACCOUNT.ID.eq(ARTICLE.ACCOUNT_ID))
.where(ACCOUNT.USER_NAME.eq("x"));

The SQL executed is as follows:

DELETE `tb_account` FROM `tb_account` 
LEFT JOIN `tb_article` ON `tb_account`.`id` = `tb_article`.`account_id` " +
WHERE `tb_account`.`user_name` = 'x'

MyBatis-Flex v1.7.3 update details are as follows:

  • New: Added support for Delete SQL multi-table association query deletion
  • New: Add methods to the code generator to facilitate obtaining all table information in certain scenarios Generator.getTables() 
  • Optimization: Rewrite the CommonsDialectImpl.wrapColumnAlias ​​method so that SQL does not keyword wrap the as keyword
  • Optimization: Code generator optimizes IDialect, adds AbstractJdbcDialect.java
  • Optimization: Add @SafeVarargs to some generic methods of QueryModel to eliminate IDE warnings. Thanks @Guan Mengyuan 
  • Repair: Fix the situation where fieldMapping basic type query is null, thank @Guan Mengyuan 
  • Fix: Multi-global Listener configuration may be missing, thanks @Ice-samll 
  • Fix: Configure the schema of the secondary table associated with the table, and the schema is lost when querying the secondary table. Thanks to @Font_C 
  • Test: Add related code test of filedMapping, thank @Guan Mengyuan 
  • Test: Add global Listener missing fixed database insertion test, thanks to @Ice-samll 

 

For code contributors, please refer to: https://mybatis-flex.com/zh/intro/what-is-mybatisflex.html#%E8%B4%A1%E7%8C%AE%E8%80%85

 

To learn more about the MyBatis-Flex framework, please refer to the link:

 

bilibili video tutorial (free):

Course 1: "MyBatis-Flex Video Tutorial"

Course Introduction: This course is recorded and lectured by Teacher Wang Shuai . Teacher Wang Shuai is also the committer who has contributed the most to the MyBatis-Flex code besides the author. He has a very in-depth understanding of both MyBatis and MyBatis-Flex.    

Course address:

https://www.bilibili.com/video/BV11h411A7cU


Course 2: "MyBatis-Flex is easy to master, a complete tutorial from zero basics to advanced applications!" Continuously updating~》

Course Introduction: This course is recorded by Teacher Zhou You. Teacher Zhou You has many years of development experience and rich teaching experience. He can explain many principles of MyBatis-Flex in an easy-to-understand and simple way.

Course address:

https://www.bilibili.com/video/BV1kF411r7ky

 

In addition, the MyBatis-Flex team has open sourced two other advanced React components. Students who use them can also pay attention to them:

-   Antd-bpmn : a high-level workflow component written based on React + Ant.design + bpmn.js, open source URL: https://gitee.com/antdadmin/antd-bpmn

- Antd-crud : a high-quality React [add, delete, modify, check] high-level component, based on Ant.Design. Open source URL: https://gitee.com/antdadmin/antd-crud 

Guess you like

Origin www.oschina.net/news/263624/mybatis-flex-1-7-3-released