<?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> <mapper namespace="com.brilliance.isc.mda.dao.EvtMapper"> <resultMap id="BaseResultMap" type="com.brilliance.isc.bo.Evt"> <result property="inr" column="inr" jdbcType="VARCHAR"/> <result property="ssninr" column="ssninr" jdbcType="VARCHAR"/> <result property="objtyp" column="objtyp" jdbcType="VARCHAR"/> <result property="objinr" column="objinr" jdbcType="VARCHAR"/> <result property="dattim" column="dattim" jdbcType="DATE"/> <result property="rtn" column="rtn" jdbcType="VARCHAR"/> <result property="txt" column="txt" jdbcType="VARCHAR"/> <result property="arcflg" column="arcflg" jdbcType="VARCHAR"/> <result property="usr" column="usr" jdbcType="VARCHAR"/> <result property="frm" column="frm" jdbcType="VARCHAR"/> <result property="etyextkey" column="etyextkey" jdbcType="VARCHAR"/> </resultMap> <sql id="Base_Column_List"> inr,ssninr,objtyp,objinr,dattim,rtn,txt,arcflg,usr,frm,etyextkey </sql> <select id="selectByPrimaryKey" resultMap="BaseResultMap"> select <include refid="Base_Column_List" /> from evt where inr = #{inr,jdbcType=VARCHAR} </select> <delete id="deleteByPrimaryKey"> delete from evt where inr = #{inr,jdbcType=VARCHAR} </delete> <insert id="insert"> insert into evt (<include refid="Base_Column_List" />) <trim prefix="values (" suffix=")" suffixOverrides=","> #{inr,jdbcType=VARCHAR}, #{ssninr,jdbcType=VARCHAR}, #{objtyp,jdbcType=VARCHAR}, #{objinr,jdbcType=VARCHAR}, #{dattim,jdbcType=DATE}, #{rtn,jdbcType=VARCHAR}, #{txt,jdbcType=VARCHAR}, #{arcflg,jdbcType=VARCHAR}, #{usr,jdbcType=VARCHAR}, #{frm,jdbcType=VARCHAR}, #{etyextkey,jdbcType=VARCHAR}, </trim> </insert> <insert id="insertSelective"> insert into evt <trim prefix="(" suffix=")" suffixOverrides=","> <if test="inr != null">inr,</if> <if test="ssninr != null">ssninr,</if> <if test="objtyp != null">objtyp,</if> <if test="objinr != null">objinr,</if> <if test="dattim != null">dattim,</if> <if test="rtn != null">rtn,</if> <if test="txt != null">txt,</if> <if test="arcflg != null">arcflg,</if> <if test="usr != null">usr,</if> <if test="frm != null">frm,</if> <if test="etyextkey != null">etyextkey,</if> </trim> <trim prefix="values (" suffix=")" suffixOverrides=","> <if test="inr != null">#{inr,jdbcType=VARCHAR}, </if> <if test="ssninr != null">#{ssninr,jdbcType=VARCHAR}, </if> <if test="objtyp != null">#{objtyp,jdbcType=VARCHAR}, </if> <if test="objinr != null">#{objinr,jdbcType=VARCHAR}, </if> <if test="dattim != null">#{dattim,jdbcType=DATE}, </if> <if test="rtn != null">#{rtn,jdbcType=VARCHAR}, </if> <if test="txt != null">#{txt,jdbcType=VARCHAR}, </if> <if test="arcflg != null">#{arcflg,jdbcType=VARCHAR}, </if> <if test="usr != null">#{usr,jdbcType=VARCHAR}, </if> <if test="frm != null">#{frm,jdbcType=VARCHAR}, </if> <if test="etyextkey != null">#{etyextkey,jdbcType=VARCHAR}, </if> </trim> </insert> <update id="updateByPrimaryKeySelective"> update evt <set> <if test="ssninr != null">ssninr = #{ssninr,jdbcType=VARCHAR},</if> <if test="objtyp != null">objtyp = #{objtyp,jdbcType=VARCHAR},</if> <if test="objinr != null">objinr = #{objinr,jdbcType=VARCHAR},</if> <if test="dattim != null">dattim = #{dattim,jdbcType=DATE},</if> <if test="rtn != null">rtn = #{rtn,jdbcType=VARCHAR},</if> <if test="txt != null">txt = #{txt,jdbcType=VARCHAR},</if> <if test="arcflg != null">arcflg = #{arcflg,jdbcType=VARCHAR},</if> <if test="usr != null">usr = #{usr,jdbcType=VARCHAR},</if> <if test="frm != null">frm = #{frm,jdbcType=VARCHAR},</if> <if test="etyextkey != null">etyextkey = #{etyextkey,jdbcType=VARCHAR},</if> </set> where inr = #{inr,jdbcType=VARCHAR} </update> <update id="updateByPrimaryKey"> update evt <set> ssninr = #{ssninr,jdbcType=VARCHAR}, objtyp = #{objtyp,jdbcType=VARCHAR}, objinr = #{objinr,jdbcType=VARCHAR}, dattim = #{dattim,jdbcType=DATE}, rtn = #{rtn,jdbcType=VARCHAR}, txt = #{txt,jdbcType=VARCHAR}, arcflg = #{arcflg,jdbcType=VARCHAR}, usr = #{usr,jdbcType=VARCHAR}, frm = #{frm,jdbcType=VARCHAR}, etyextkey = #{etyextkey,jdbcType=VARCHAR}, </set> where inr = #{inr,jdbcType=VARCHAR} </update> <delete id="deleteByIds"> delete from act where inr in <foreach item="item" index="index" collection="collection" open="(" separator="," close=")"> #{item} </foreach> </delete> <update id="dyncUpdate"> update evt <set> <if test="module.ssninr != null">ssninr = #{module.ssninr,jdbcType=VARCHAR},</if> <if test="module.objtyp != null">objtyp = #{module.objtyp,jdbcType=VARCHAR},</if> <if test="module.objinr != null">objinr = #{module.objinr,jdbcType=VARCHAR},</if> <if test="module.dattim != null">dattim = #{module.dattim,jdbcType=DATE},</if> <if test="module.rtn != null">rtn = #{module.rtn,jdbcType=VARCHAR},</if> <if test="module.txt != null">txt = #{module.txt,jdbcType=VARCHAR},</if> <if test="module.arcflg != null">arcflg = #{module.arcflg,jdbcType=VARCHAR},</if> <if test="module.usr != null">usr = #{module.usr,jdbcType=VARCHAR},</if> <if test="module.frm != null">frm = #{module.frm,jdbcType=VARCHAR},</if> <if test="module.etyextkey != null">etyextkey = #{module.etyextkey,jdbcType=VARCHAR},</if> </set> ${conditions} </update> <delete id="dyncDelete"> ${sql} </delete> <select id="dyncRead" resultMap="BaseResultMap"> ${sql} </select> </mapper>