参考博客:mybatis批量删除(逻辑删除)
参考博客:Mybatis实现批量删除操作
Mapper
<delete id="deleteByPrimaryKeyList">
delete from SYS_RIGHT_USER
where USER_CODE in
<foreach item="item" collection="userCode" open="(" separator="," close=")">
#{item}
</foreach>
</delete>
dao
int deleteByPrimaryKeyList(@Param("userCode") String[] userCode);