sql语句更新xml基本写法
sql语句更新xml基本写法
<mapper namespace="com.keyou.dao.samSystem.SamApplyDao"> <update id="updateRejectSamApply"> UPDATE SAM_APPLY <trim prefix="set" suffixOverrides=","> <if test="samApplyRejectInputParam.rejectOpinion!=null"> SAM_APPLY.REJECTOPINION=#{samApplyRejectInputParam.rejectOpinion}, </if> </trim> <where> <if test="samApplyRejectInputParam.applyguid!=null"> SAM_APPLY.APPLYGUID=#{samApplyRejectInputParam.applyguid} </if> </where> </update> </mapper>
入参对象samApplyRejectInputParam与接口方法中的@param标志的参数对应如
boolean updateRejectSamApply(@Param("samApplyRejectInputParam")SAMApplyRejectInputParam samApplyRejectInputParam);
本文来自博客园,作者:King-DA,转载请注明原文链接:https://www.cnblogs.com/qingmuchuanqi48/p/14940336.html