commandInfoMapper.xml 8.9 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.sy.mapper.commandInfoMapper">
  <resultMap id="BaseResultMap" type="com.sy.model.commandInfo">
    <id column="SEQ_NO" jdbcType="VARCHAR" property="seqNo" />
    <result column="sender" jdbcType="VARCHAR" property="sender" />
    <result column="receiver" jdbcType="VARCHAR" property="receiver" />
    <result column="seqn" jdbcType="VARCHAR" property="seqn" />
    <result column="sendtime" jdbcType="TIMESTAMP" property="sendtime" />
    <result column="btype" jdbcType="VARCHAR" property="btype" />
    <result column="stype" jdbcType="VARCHAR" property="stype" />
    <result column="AREA_ID" jdbcType="VARCHAR" property="areaId" />
    <result column="CHNL_NO" jdbcType="VARCHAR" property="chnlNo" />
    <result column="I_E_TYPE" jdbcType="VARCHAR" property="iEType" />
    <result column="CHECK_RESULT" jdbcType="VARCHAR" property="checkResult" />
    <result column="VE_NAME" jdbcType="VARCHAR" property="veName" />
    <result column="GPS_ID" jdbcType="VARCHAR" property="gpsId" />
    <result column="ORIGIN_CUSTOMS" jdbcType="VARCHAR" property="originCustoms" />
    <result column="DEST_CUSTOMS" jdbcType="VARCHAR" property="destCustoms" />
    <result column="ESEAL_ID" jdbcType="VARCHAR" property="esealId" />
    <result column="SEAL_KEY" jdbcType="VARCHAR" property="sealKey" />
    <result column="FORM_ID" jdbcType="VARCHAR" property="formId" />
    <result column="OP_HINT" jdbcType="VARCHAR" property="opHint" />
  </resultMap>
  <sql id="Base_Column_List">
    SEQ_NO, sender, receiver, seqn, sendtime, btype, stype, AREA_ID, CHNL_NO, I_E_TYPE, 
    CHECK_RESULT, VE_NAME, GPS_ID, ORIGIN_CUSTOMS, DEST_CUSTOMS, ESEAL_ID, SEAL_KEY, 
    FORM_ID, OP_HINT
  </sql>
  <select id="selectByPrimaryKey" parameterType="java.lang.String" resultMap="BaseResultMap">
    select 
    <include refid="Base_Column_List" />
    from commandinfo
    where SEQ_NO = #{seqNo,jdbcType=VARCHAR}
  </select>
  <delete id="deleteByPrimaryKey" parameterType="java.lang.String">
    delete from commandinfo
    where SEQ_NO = #{seqNo,jdbcType=VARCHAR}
  </delete>
  <insert id="insert" parameterType="com.sy.model.commandInfo">
    insert into commandinfo (SEQ_NO, sender, receiver, 
      seqn, sendtime, btype, 
      stype, AREA_ID, CHNL_NO, 
      I_E_TYPE, CHECK_RESULT, VE_NAME, 
      GPS_ID, ORIGIN_CUSTOMS, DEST_CUSTOMS, 
      ESEAL_ID, SEAL_KEY, FORM_ID, 
      OP_HINT)
    values (#{seqNo,jdbcType=VARCHAR}, #{sender,jdbcType=VARCHAR}, #{receiver,jdbcType=VARCHAR}, 
      #{seqn,jdbcType=VARCHAR}, #{sendtime,jdbcType=TIMESTAMP}, #{btype,jdbcType=VARCHAR}, 
      #{stype,jdbcType=VARCHAR}, #{areaId,jdbcType=VARCHAR}, #{chnlNo,jdbcType=VARCHAR}, 
      #{iEType,jdbcType=VARCHAR}, #{checkResult,jdbcType=VARCHAR}, #{veName,jdbcType=VARCHAR}, 
      #{gpsId,jdbcType=VARCHAR}, #{originCustoms,jdbcType=VARCHAR}, #{destCustoms,jdbcType=VARCHAR}, 
      #{esealId,jdbcType=VARCHAR}, #{sealKey,jdbcType=VARCHAR}, #{formId,jdbcType=VARCHAR}, 
      #{opHint,jdbcType=VARCHAR})
  </insert>
  <insert id="insertSelective" parameterType="com.sy.model.commandInfo">
    insert into commandinfo
    <trim prefix="(" suffix=")" suffixOverrides=",">
      <if test="seqNo != null">
        SEQ_NO,
      </if>
      <if test="sender != null">
        sender,
      </if>
      <if test="receiver != null">
        receiver,
      </if>
      <if test="seqn != null">
        seqn,
      </if>
      <if test="sendtime != null">
        sendtime,
      </if>
      <if test="btype != null">
        btype,
      </if>
      <if test="stype != null">
        stype,
      </if>
      <if test="areaId != null">
        AREA_ID,
      </if>
      <if test="chnlNo != null">
        CHNL_NO,
      </if>
      <if test="iEType != null">
        I_E_TYPE,
      </if>
      <if test="checkResult != null">
        CHECK_RESULT,
      </if>
      <if test="veName != null">
        VE_NAME,
      </if>
      <if test="gpsId != null">
        GPS_ID,
      </if>
      <if test="originCustoms != null">
        ORIGIN_CUSTOMS,
      </if>
      <if test="destCustoms != null">
        DEST_CUSTOMS,
      </if>
      <if test="esealId != null">
        ESEAL_ID,
      </if>
      <if test="sealKey != null">
        SEAL_KEY,
      </if>
      <if test="formId != null">
        FORM_ID,
      </if>
      <if test="opHint != null">
        OP_HINT,
      </if>
    </trim>
    <trim prefix="values (" suffix=")" suffixOverrides=",">
      <if test="seqNo != null">
        #{seqNo,jdbcType=VARCHAR},
      </if>
      <if test="sender != null">
        #{sender,jdbcType=VARCHAR},
      </if>
      <if test="receiver != null">
        #{receiver,jdbcType=VARCHAR},
      </if>
      <if test="seqn != null">
        #{seqn,jdbcType=VARCHAR},
      </if>
      <if test="sendtime != null">
        #{sendtime,jdbcType=TIMESTAMP},
      </if>
      <if test="btype != null">
        #{btype,jdbcType=VARCHAR},
      </if>
      <if test="stype != null">
        #{stype,jdbcType=VARCHAR},
      </if>
      <if test="areaId != null">
        #{areaId,jdbcType=VARCHAR},
      </if>
      <if test="chnlNo != null">
        #{chnlNo,jdbcType=VARCHAR},
      </if>
      <if test="iEType != null">
        #{iEType,jdbcType=VARCHAR},
      </if>
      <if test="checkResult != null">
        #{checkResult,jdbcType=VARCHAR},
      </if>
      <if test="veName != null">
        #{veName,jdbcType=VARCHAR},
      </if>
      <if test="gpsId != null">
        #{gpsId,jdbcType=VARCHAR},
      </if>
      <if test="originCustoms != null">
        #{originCustoms,jdbcType=VARCHAR},
      </if>
      <if test="destCustoms != null">
        #{destCustoms,jdbcType=VARCHAR},
      </if>
      <if test="esealId != null">
        #{esealId,jdbcType=VARCHAR},
      </if>
      <if test="sealKey != null">
        #{sealKey,jdbcType=VARCHAR},
      </if>
      <if test="formId != null">
        #{formId,jdbcType=VARCHAR},
      </if>
      <if test="opHint != null">
        #{opHint,jdbcType=VARCHAR},
      </if>
    </trim>
  </insert>
  <update id="updateByPrimaryKeySelective" parameterType="com.sy.model.commandInfo">
    update commandinfo
    <set>
      <if test="sender != null">
        sender = #{sender,jdbcType=VARCHAR},
      </if>
      <if test="receiver != null">
        receiver = #{receiver,jdbcType=VARCHAR},
      </if>
      <if test="seqn != null">
        seqn = #{seqn,jdbcType=VARCHAR},
      </if>
      <if test="sendtime != null">
        sendtime = #{sendtime,jdbcType=TIMESTAMP},
      </if>
      <if test="btype != null">
        btype = #{btype,jdbcType=VARCHAR},
      </if>
      <if test="stype != null">
        stype = #{stype,jdbcType=VARCHAR},
      </if>
      <if test="areaId != null">
        AREA_ID = #{areaId,jdbcType=VARCHAR},
      </if>
      <if test="chnlNo != null">
        CHNL_NO = #{chnlNo,jdbcType=VARCHAR},
      </if>
      <if test="iEType != null">
        I_E_TYPE = #{iEType,jdbcType=VARCHAR},
      </if>
      <if test="checkResult != null">
        CHECK_RESULT = #{checkResult,jdbcType=VARCHAR},
      </if>
      <if test="veName != null">
        VE_NAME = #{veName,jdbcType=VARCHAR},
      </if>
      <if test="gpsId != null">
        GPS_ID = #{gpsId,jdbcType=VARCHAR},
      </if>
      <if test="originCustoms != null">
        ORIGIN_CUSTOMS = #{originCustoms,jdbcType=VARCHAR},
      </if>
      <if test="destCustoms != null">
        DEST_CUSTOMS = #{destCustoms,jdbcType=VARCHAR},
      </if>
      <if test="esealId != null">
        ESEAL_ID = #{esealId,jdbcType=VARCHAR},
      </if>
      <if test="sealKey != null">
        SEAL_KEY = #{sealKey,jdbcType=VARCHAR},
      </if>
      <if test="formId != null">
        FORM_ID = #{formId,jdbcType=VARCHAR},
      </if>
      <if test="opHint != null">
        OP_HINT = #{opHint,jdbcType=VARCHAR},
      </if>
    </set>
    where SEQ_NO = #{seqNo,jdbcType=VARCHAR}
  </update>
  <update id="updateByPrimaryKey" parameterType="com.sy.model.commandInfo">
    update commandinfo
    set sender = #{sender,jdbcType=VARCHAR},
      receiver = #{receiver,jdbcType=VARCHAR},
      seqn = #{seqn,jdbcType=VARCHAR},
      sendtime = #{sendtime,jdbcType=TIMESTAMP},
      btype = #{btype,jdbcType=VARCHAR},
      stype = #{stype,jdbcType=VARCHAR},
      AREA_ID = #{areaId,jdbcType=VARCHAR},
      CHNL_NO = #{chnlNo,jdbcType=VARCHAR},
      I_E_TYPE = #{iEType,jdbcType=VARCHAR},
      CHECK_RESULT = #{checkResult,jdbcType=VARCHAR},
      VE_NAME = #{veName,jdbcType=VARCHAR},
      GPS_ID = #{gpsId,jdbcType=VARCHAR},
      ORIGIN_CUSTOMS = #{originCustoms,jdbcType=VARCHAR},
      DEST_CUSTOMS = #{destCustoms,jdbcType=VARCHAR},
      ESEAL_ID = #{esealId,jdbcType=VARCHAR},
      SEAL_KEY = #{sealKey,jdbcType=VARCHAR},
      FORM_ID = #{formId,jdbcType=VARCHAR},
      OP_HINT = #{opHint,jdbcType=VARCHAR}
    where SEQ_NO = #{seqNo,jdbcType=VARCHAR}
  </update>
</mapper>