T_TXD_FWBSTATUSMapper.xml 4.0 KB
<?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.example.demo.mapper.T_TXD_FWBSTATUSMapper" >
  <resultMap id="BaseResultMap" type="com.example.demo.model.T_TXD_FWBSTATUS" >
    <id column="FID" property="fid" jdbcType="DECIMAL" />
    <result column="REASONCODE" property="reasoncode" jdbcType="VARCHAR" />
    <result column="OCCURRENCEDATETIME" property="occurrencedatetime" jdbcType="TIMESTAMP" />
    <result column="DATETIMETYPECODE" property="datetimetypecode" jdbcType="VARCHAR" />
    <result column="ID" property="id" jdbcType="VARCHAR" />
    <result column="TXD_FWB_ID" property="txdFwbId" jdbcType="DECIMAL" />
  </resultMap>
  <sql id="Base_Column_List" >
    FID, REASONCODE, OCCURRENCEDATETIME, DATETIMETYPECODE, ID, TXD_FWB_ID
  </sql>
  <select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.math.BigDecimal" >
    select 
    <include refid="Base_Column_List" />
    from T_TXD_FWBSTATUS
    where FID = #{fid,jdbcType=DECIMAL}
  </select>
  <delete id="deleteByPrimaryKey" parameterType="java.math.BigDecimal" >
    delete from T_TXD_FWBSTATUS
    where FID = #{fid,jdbcType=DECIMAL}
  </delete>
  <insert id="insert" parameterType="com.example.demo.model.T_TXD_FWBSTATUS" >
    insert into T_TXD_FWBSTATUS (FID, REASONCODE, OCCURRENCEDATETIME, 
      DATETIMETYPECODE, ID, TXD_FWB_ID
      )
    values (#{fid,jdbcType=DECIMAL}, #{reasoncode,jdbcType=VARCHAR}, #{occurrencedatetime,jdbcType=TIMESTAMP}, 
      #{datetimetypecode,jdbcType=VARCHAR}, #{id,jdbcType=VARCHAR}, #{txdFwbId,jdbcType=DECIMAL}
      )
  </insert>
  <insert id="insertSelective" parameterType="com.example.demo.model.T_TXD_FWBSTATUS" >
    insert into T_TXD_FWBSTATUS
    <trim prefix="(" suffix=")" suffixOverrides="," >
      <if test="fid != null" >
        FID,
      </if>
      <if test="reasoncode != null" >
        REASONCODE,
      </if>
      <if test="occurrencedatetime != null" >
        OCCURRENCEDATETIME,
      </if>
      <if test="datetimetypecode != null" >
        DATETIMETYPECODE,
      </if>
      <if test="id != null" >
        ID,
      </if>
      <if test="txdFwbId != null" >
        TXD_FWB_ID,
      </if>
    </trim>
    <trim prefix="values (" suffix=")" suffixOverrides="," >
      <if test="fid != null" >
        #{fid,jdbcType=DECIMAL},
      </if>
      <if test="reasoncode != null" >
        #{reasoncode,jdbcType=VARCHAR},
      </if>
      <if test="occurrencedatetime != null" >
        #{occurrencedatetime,jdbcType=TIMESTAMP},
      </if>
      <if test="datetimetypecode != null" >
        #{datetimetypecode,jdbcType=VARCHAR},
      </if>
      <if test="id != null" >
        #{id,jdbcType=VARCHAR},
      </if>
      <if test="txdFwbId != null" >
        #{txdFwbId,jdbcType=DECIMAL},
      </if>
    </trim>
  </insert>
  <update id="updateByPrimaryKeySelective" parameterType="com.example.demo.model.T_TXD_FWBSTATUS" >
    update T_TXD_FWBSTATUS
    <set >
      <if test="reasoncode != null" >
        REASONCODE = #{reasoncode,jdbcType=VARCHAR},
      </if>
      <if test="occurrencedatetime != null" >
        OCCURRENCEDATETIME = #{occurrencedatetime,jdbcType=TIMESTAMP},
      </if>
      <if test="datetimetypecode != null" >
        DATETIMETYPECODE = #{datetimetypecode,jdbcType=VARCHAR},
      </if>
      <if test="id != null" >
        ID = #{id,jdbcType=VARCHAR},
      </if>
      <if test="txdFwbId != null" >
        TXD_FWB_ID = #{txdFwbId,jdbcType=DECIMAL},
      </if>
    </set>
    where FID = #{fid,jdbcType=DECIMAL}
  </update>
  <update id="updateByPrimaryKey" parameterType="com.example.demo.model.T_TXD_FWBSTATUS" >
    update T_TXD_FWBSTATUS
    set REASONCODE = #{reasoncode,jdbcType=VARCHAR},
      OCCURRENCEDATETIME = #{occurrencedatetime,jdbcType=TIMESTAMP},
      DATETIMETYPECODE = #{datetimetypecode,jdbcType=VARCHAR},
      ID = #{id,jdbcType=VARCHAR},
      TXD_FWB_ID = #{txdFwbId,jdbcType=DECIMAL}
    where FID = #{fid,jdbcType=DECIMAL}
  </update>
</mapper>