oracle的批量操作sql语句

1.批量删除/批量更新

 mapper:

<update id="updatePrjStateByFPrjId" parameterType="string">
        update table_name 
          set f_stat = #{f_stat,jdbcType=VARCHAR}, f_s_id = '1'
        where pk_id in
        <foreach collection="ids" item="id" open="(" separator="," close=")" >
            #{id,jdbcType=VARCHAR} 
        </foreach>
    </update>

 dao:

int updatePrjStateByFPrjId(@Param("f_stat")String f_stat, @Param("ids")String[] ids);

 

原文地址:https://www.cnblogs.com/shiyun32/p/9242747.html