finds.dev← search

// the find

yulichang/mybatis-plus-join

★ 1,523 · Java · Apache-2.0 · updated Sep 2026

支持连表查询的mybatis-plus,mybatis-plus风格的连表操作提供left join、right join等操作

A MyBatis-Plus extension that generates multi-table SQL (left, right and inner joins, plus update and delete joins) from the same wrapper API that MyBatis-Plus users already write. It is aimed at Spring Boot projects on MyBatis-Plus 3.5.17 or later that have tired of hand-written join XML and per-query result maps.

- Join conditions are method references, for example leftJoin(AddressDO.class, AddressDO::getUserId, UserDO::getId), so a renamed field fails at compile time instead of at query time.

- selectJoinList and selectJoinPage take a DTO class and map the joined columns onto it, which removes most of the ResultMap boilerplate that multi-table queries usually need.

- UpdateJoin and DeleteJoin sit alongside the select methods. UPDATE ... JOIN and DELETE ... JOIN are awkward to write by hand and most wrappers ignore them.

- The source tree includes Kotlin and annotation-processor wrapper variants next to the reflection-based one, which gives teams a choice about how column metadata gets resolved.

- Pagination goes through a custom interceptor that rewrites SQL (the tree has a pagination package with DialectWrapper, ParseHelper and a JSqlParser adapter). Joins with subqueries or dialect-specific clauses are where that rewrite is most likely to break, and the README says nothing about what it supports.

- Version coupling is strict. Release 1.5.9 needs MyBatis-Plus 3.5.17 or later, and 1.5.8 covers 3.1.2 to 3.5.16. Every upstream MyBatis-Plus upgrade becomes a version-matching exercise, and the library depends on MyBatis-Plus internals that can change.

- The README is in Chinese and shows a single left-join example. The detailed usage docs are only linked from it, so teams who cannot read Chinese have little to go on before adopting it.

View on GitHub → Homepage ↗

// want more like this?

We dig through GitHub every week and send a few repos picked for what you actually care about — each with an honest take like this one.

Get finds in your inbox → Search again →