<?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.xt.hb.data.cbyj.mapper.CbyjAreaMapper" >
  <resultMap id="BaseResultMap" type="com.xt.hb.data.cbyj.model.CbyjArea" >
    <id column="ID" property="id" jdbcType="DECIMAL" />
    <result column="AREANAME" property="areaname" jdbcType="VARCHAR" />
    <result column="SZD" property="szd" jdbcType="VARCHAR" />
    <result column="BZ" property="bz" jdbcType="VARCHAR" />
  </resultMap>
  <delete id="deleteByPrimaryKey" parameterType="long" >
    delete from T_GIS_CBYJ_AREA
    where ID = #{id,jdbcType=INTEGER}
  </delete>
  <insert id="insert" parameterType="com.xt.hb.data.cbyj.model.CbyjArea" >
    insert into T_GIS_CBYJ_AREA (ID, AREANAME,SZD,BZ)
    values (#{id,jdbcType=INTEGER}, #{areaname,jdbcType=VARCHAR}, #{szd,jdbcType=VARCHAR}, #{bz,jdbcType=VARCHAR})
  </insert>
  <update id="updateByPrimaryKey" parameterType="com.xt.hb.data.cbyj.model.CbyjArea" >
    update T_GIS_CBYJ_AREA
    set AREANAME = #{areaname,jdbcType=VARCHAR},
    set SZD = #{szd,jdbcType=VARCHAR},
    set BZ = #{bz,jdbcType=VARCHAR}
    where ID = #{id,jdbcType=INTEGER}
  </update>
  <select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="long" >
    select ID, AREANAME, SZD, BZ
    from T_GIS_CBYJ_AREA
    where ID = #{id,jdbcType=INTEGER}
  </select>
  <select id="selectAll" resultMap="BaseResultMap" >
    select ID, AREANAME, SZD, BZ
    from T_GIS_CBYJ_AREA
  </select>
</mapper>