Update dependency org.mybatis.dynamic-sql:mybatis-dynamic-sql to v1.5.1 #74
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR contains the following updates:
1.5.0
->1.5.1
Release Notes
mybatis/mybatis-dynamic-sql (org.mybatis.dynamic-sql:mybatis-dynamic-sql)
v1.5.1
This is a minor release with several enhancements.
GitHub milestone: https://github.com/mybatis/mybatis-dynamic-sql/milestone/13?closed=1
Case Expressions and Cast Function
We've added support for CASE expressions to the library. Both simple and searched case expressions are supported.
This is a fairly extensive enhancement as case expressions are quite complex, but we were able to reuse many of the
building blocks from the WHERE and HAVING support already in the library. You should be able to build CASE expressions
with relatively few limitations.
It is also common to use a CAST function with CASE expressions, so we have added CAST as a built-in function
in the library.
The DSL for both Java and Kotlin has been updated to fully support CASE expressions in the same idiomatic forms
as other parts of the library.
We've tested this extensively and the code is, of course, 100% covered by test code. But it is possible that we've not
covered every scenario. Please let us know if you find issues.
Full documentation is available here:
The pull request for this change is (#761)
Parameter Values in Joins
We've added the ability to specify typed values in equi-joins. This allows you to avoid the use of constants, and it is
type safe. For example:
Note the phrase
and(orderLine.orderId, equalTo(1))
which will be rendered with a bound SQL parameter. Currently, thiscapability is limited to equality only. If you have a use for other functions (not equal, less then, greater than, etc.)
please let us know.
In order to add this capability, we've modified the join DSL to add type information to the join columns. This should
be source code compatible with most uses. There could be an issue if you are joining tables with columns of different
types - which is a rare usage. Please let us know if this causes an undo hardship.
Other Changes
it is now easier to support more complex functions - such as the aggregate function
sum(id < 5)
which is theinitial enhancement request that inspired this change. As a result of the changes, one method is deprecated
in the
BasicColumn
object. If you have implemented any custom functions, please note this deprecation and updateyour code accordingly. (#662)
the parameter map and a bind parameter marker is rendered. (#738)
will enable a future change where conditions could decide to allow rendering even if they are considered empty (such
as rendering empty lists). This change should be transparent to users unless they have implemented custom conditions.
a good safety measure in some cases.
natural use of an Array as an input for an "in" condition. They also allow easy reuse of a vararg argument in a
function. (#781)
Configuration
📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).
🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.
♻ Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.
🔕 Ignore: Close this PR and you won't be reminded about this update again.
This PR has been generated by Mend Renovate. View repository job log here.