2020
10-20
10-20
Mybatis传入List实现批量更新的示例代码
Dao层写法/***批量更新新库存*@paramlist*@return*/intupdateNewStock(@Param(value="list")List<GreenBeanMsg>list);xml具体实现代码<updateid="updateNewStock"parameterType="java.util.List"><foreachcollection="list"item="bean"index="index"open=""close=""separator=";">UPDATEgreen_beans<set>stock=#{bean.stock}</set><where>beanUid=...
继续阅读 >