l.id_,l.group_id_, l.prize_id_,d.name_,d.reward_type_, l.user_id_, l.create_on_ and l.prize_id_ = #{id} and l.user_id_ = #{userId} and d.name_ like concat('%',#{name},'%') and d.reward_type_ like concat('%',#{rewardType},'%') and l.group_id_ = #{groupId} and l.create_on_ >= #{startDate} and l.create_on_ <= #{endDate} and u.organ_id_ = #{organId} delete from luck_draw_log where id_ = #{id,jdbcType=BIGINT} insert into luck_draw_log (id_,group_id_, prize_id_, user_id_, create_on_) values (#{id,jdbcType=BIGINT}, #{groupId,jdbcType=INTEGER}, #{prizeId,jdbcType=INTEGER}, #{userId,jdbcType=BIGINT}, #{createOn,jdbcType=TIMESTAMP}) update luck_draw_log group_id_ = #{groupId,jdbcType=INTEGER}, prize_id_ = #{prizeId,jdbcType=INTEGER}, user_id_ = #{userId,jdbcType=BIGINT}, create_on_ = #{createOn,jdbcType=TIMESTAMP}, where id_ = #{id,jdbcType=BIGINT}