Mybatis功能整理

来源:互联网 发布:js获取radio选中状态 编辑:程序博客网 时间:2024/06/01 08:11

一、批量插入功能

<insert id="batchInsert">        INSERT INTO message(            user_range,            to_user_id,            type,            src_id        ) VALUES         <foreach collection="list" item="item" index="index" separator="," >              (#{item.userRange},#{item.toUserId},#{item.type},#{item.srcId})          </foreach>    </insert>
原创粉丝点击