总结
<!-- 批量删除 --> <delete id="deleteAll"> delete from tbl_emp where emp_id in <!-- 如果传入的是list,那么collection的值为list,如果是array不可变数组,则collection的值为array --> <foreach collection="array" item="id" open="(" close=")" separator=","> #{id} </foreach> </delete>