azraelee opened a new issue #5797:
URL: https://github.com/apache/shardingsphere/issues/5797
这个是我的项目sql:
update xxx_table
<trim prefix="set" suffixOverrides=",">
<trim prefix="column1= case" suffix="end," >
<foreach collection="list" item="item" index="index">
<if test="item.column1 != null">
when id = #{item.id} then #{item.column1}
</if>
</foreach>
else column1
</trim>
<trim prefix="column2 = case" suffix="end," >
<foreach collection="list" item="item" index="index">
<if test="item.column2 != null">
when id = #{item.id} then #{item.column2}
</if>
</foreach>
else column2
</trim>
</trim>
where
<foreach collection="list" item="item" open="( " separator=") or ("
close=" )">
id = #{item.id}
</foreach>
当解析 <trim prefix="column1= case" suffix="end," > 这句时,
执行CaseExpressionContext#simpleExpr() 会返回空指针异常
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]