例子有点憨,将就看
<choose>
<when test="id = 1">
and id = 2
</when>
<when test="id = 2">
and id = 3
</when>
<otherwise>
and id is null
</otherwise>
</choose>
choose中的when会不会匹配多个? 不会,从上到下判断,匹配到一个之后,其他的就不会匹配了
例子有点憨,将就看
<choose>
<when test="id = 1">
and id = 2
</when>
<when test="id = 2">
and id = 3
</when>
<otherwise>
and id is null
</otherwise>
</choose>
choose中的when会不会匹配多个? 不会,从上到下判断,匹配到一个之后,其他的就不会匹配了