| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301 |
- <?xml version="1.0" encoding="UTF-8"?>
- <!-- 核三框架升级自动生成mapper文件 -->
- <!-- DEMO_HDXX表牵涉到的sql文件 -->
- <!DOCTYPE mapper
- PUBLIC "-//ibatis.apache.org//DTD Mapper 3.0//EN"
- "http://ibatis.apache.org/dtd/ibatis-3-mapper.dtd">
- <mapper namespace="DEMO_HDXX">
- <!-- DEMO_HDXX 全字段 -->
- <sql id="DEMO_HDXX_COL">
- SPSJ,SPBZ,BZ,HDID,HDBT,YWLSH,HDKSSJ,
- HDJSSJ,HDLB,HDFQR,JBR,JBSJ,SPR
- </sql>
- <!-- DEMO_HDXX 选择字段 -->
- <sql id="DEMO_HDXX_COLSEL">
- <trim suffixOverrides=",">
- <if test="SPSJ != null">
- SPSJ,
- </if>
- <if test="SPBZ != null">
- SPBZ,
- </if>
- <if test="BZ != null">
- BZ,
- </if>
- <if test="HDID != null">
- HDID,
- </if>
- <if test="HDBT != null">
- HDBT,
- </if>
- <if test="YWLSH != null">
- YWLSH,
- </if>
- <if test="HDKSSJ != null">
- HDKSSJ,
- </if>
- <if test="HDJSSJ != null">
- HDJSSJ,
- </if>
- <if test="HDLB != null">
- HDLB,
- </if>
- <if test="HDFQR != null">
- HDFQR,
- </if>
- <if test="JBR != null">
- JBR,
- </if>
- <if test="JBSJ != null">
- JBSJ,
- </if>
- <if test="SPR != null">
- SPR
- </if>
- </trim>
- </sql>
- <!-- DEMO_HDXX 记录数 -->
- <select id="DEMO_HDXX_CNT" parameterType="hashmap" resultType="long">
- select count(1)
- from DEMO_HDXX
- <where>
- <if test="SPSJ != null">
- and SPSJ=#{SPSJ}
- </if>
- <if test="SPBZ != null">
- and SPBZ=#{SPBZ}
- </if>
- <if test="BZ != null">
- and BZ=#{BZ}
- </if>
- <if test="HDID != null">
- and HDID=#{HDID}
- </if>
- <if test="HDBT != null">
- and HDBT=#{HDBT}
- </if>
- <if test="YWLSH != null">
- and YWLSH=#{YWLSH}
- </if>
- <if test="HDKSSJ != null">
- and HDKSSJ=#{HDKSSJ}
- </if>
- <if test="HDJSSJ != null">
- and HDJSSJ=#{HDJSSJ}
- </if>
- <if test="HDLB != null">
- and HDLB=#{HDLB}
- </if>
- <if test="HDFQR != null">
- and HDFQR=#{HDFQR}
- </if>
- <if test="JBR != null">
- and JBR=#{JBR}
- </if>
- <if test="JBSJ != null">
- and JBSJ=#{JBSJ}
- </if>
- <if test="SPR != null">
- and SPR=#{SPR}
- </if>
- </where>
- </select>
- <!-- DEMO_HDXX 全字段查询 -->
- <select id="DEMO_HDXX_Q" parameterType="hashmap" resultType="hashmap">
- select
- <include refid="DEMO_HDXX_COL" /> <!--引用前边定义的所有字段 -->
- from DEMO_HDXX
- <where>
- <if test="SPSJ != null">
- and SPSJ=#{SPSJ}
- </if>
- <if test="SPBZ != null">
- and SPBZ=#{SPBZ}
- </if>
- <if test="BZ != null">
- and BZ=#{BZ}
- </if>
- <if test="HDID != null">
- and HDID=#{HDID}
- </if>
- <if test="HDBT != null">
- and HDBT=#{HDBT}
- </if>
- <if test="YWLSH != null">
- and YWLSH=#{YWLSH}
- </if>
- <if test="HDKSSJ != null">
- and HDKSSJ=#{HDKSSJ}
- </if>
- <if test="HDJSSJ != null">
- and HDJSSJ=#{HDJSSJ}
- </if>
- <if test="HDLB != null">
- and HDLB=#{HDLB}
- </if>
- <if test="HDFQR != null">
- and HDFQR=#{HDFQR}
- </if>
- <if test="JBR != null">
- and JBR=#{JBR}
- </if>
- <if test="JBSJ != null">
- and JBSJ=#{JBSJ}
- </if>
- <if test="SPR != null">
- and SPR=#{SPR}
- </if>
- </where>
- </select>
- <!-- DEMO_HDXX 选择查询 -->
- <select id="DEMO_HDXX_QS" parameterType="hashmap" resultType="hashmap">
- select
- <include refid="DEMO_HDXX_COLSEL" /> <!--引用前边定义的所有字段 -->
- from DEMO_HDXX
- <where>
- <if test="SPSJ != null">
- and SPSJ=#{SPSJ}
- </if>
- <if test="SPBZ != null">
- and SPBZ=#{SPBZ}
- </if>
- <if test="BZ != null">
- and BZ=#{BZ}
- </if>
- <if test="HDID != null">
- and HDID=#{HDID}
- </if>
- <if test="HDBT != null">
- and HDBT=#{HDBT}
- </if>
- <if test="YWLSH != null">
- and YWLSH=#{YWLSH}
- </if>
- <if test="HDKSSJ != null">
- and HDKSSJ=#{HDKSSJ}
- </if>
- <if test="HDJSSJ != null">
- and HDJSSJ=#{HDJSSJ}
- </if>
- <if test="HDLB != null">
- and HDLB=#{HDLB}
- </if>
- <if test="HDFQR != null">
- and HDFQR=#{HDFQR}
- </if>
- <if test="JBR != null">
- and JBR=#{JBR}
- </if>
- <if test="JBSJ != null">
- and JBSJ=#{JBSJ}
- </if>
- <if test="SPR != null">
- and SPR=#{SPR}
- </if>
- </where>
- </select>
- <!-- DEMO_HDXX 插入 -->
- <insert id="DEMO_HDXX_I" parameterType="hashmap">
- insert into DEMO_HDXX (
- SPSJ,SPBZ,BZ,HDID,HDBT,YWLSH,HDKSSJ,
- HDJSSJ,HDLB,HDFQR,JBR,JBSJ,SPR,YHZH
- ) values (
- #{SPSJ},#{SPBZ},#{BZ},#{HDID},#{HDBT},#{YWLSH},#{HDKSSJ},
- #{HDJSSJ},#{HDLB},#{HDFQR},#{JBR},#{JBSJ},#{SPR},#{YHZH}
- )
- </insert>
- <!-- DEMO_HDXX 插入-类型映射 -->
- <insert id="DEMO_HDXX_IT" parameterType="hashmap">
- insert into DEMO_HDXX (
- SPSJ,SPBZ,BZ,HDID,HDBT,YWLSH,HDKSSJ,
- HDJSSJ,HDLB,HDFQR,JBR,JBSJ,SPR
- ) values (
- #{SPSJ ,javaType=long,jdbcType=NUMERIC},#{SPBZ ,javaType=string,jdbcType=VARCHAR},
- #{BZ ,javaType=string,jdbcType=VARCHAR},#{HDID ,javaType=long,jdbcType=NUMERIC},#{HDBT ,javaType=string,jdbcType=VARCHAR},
- #{YWLSH ,javaType=string,jdbcType=VARCHAR},#{HDKSSJ ,javaType=long,jdbcType=NUMERIC},#{HDJSSJ ,javaType=long,jdbcType=NUMERIC},
- #{HDLB ,javaType=string,jdbcType=VARCHAR},#{HDFQR ,javaType=string,jdbcType=VARCHAR},#{JBR ,javaType=string,jdbcType=VARCHAR},
- #{JBSJ ,javaType=long,jdbcType=NUMERIC},#{SPR ,javaType=string,jdbcType=VARCHAR}
- )
- </insert>
- <!-- DEMO_HDXX 选择字段插入 -->
- <insert id="DEMO_HDXX_IS" parameterType="hashmap">
- insert into DEMO_HDXX (
- <trim suffixOverrides=",">
- <if test="SPSJ != null">SPSJ,</if>
- <if test="SPBZ != null">SPBZ,</if>
- <if test="BZ != null">BZ,</if>
- <if test="HDID != null">HDID,</if>
- <if test="HDBT != null">HDBT,</if>
- <if test="YWLSH != null">YWLSH,</if>
- <if test="HDKSSJ != null">HDKSSJ,</if>
- <if test="HDJSSJ != null">HDJSSJ,</if>
- <if test="HDLB != null">HDLB,</if>
- <if test="HDFQR != null">HDFQR,</if>
- <if test="JBR != null">JBR,</if>
- <if test="JBSJ != null">JBSJ,</if>
- <if test="SPR != null">SPR,</if>
- <if test="YHZH != null">YHZH,</if>
- </trim>
- ) values (
- <trim suffixOverrides=",">
- <if test="SPSJ != null">#{SPSJ},</if>
- <if test="SPBZ != null">#{SPBZ},</if>
- <if test="BZ != null">#{BZ},</if>
- <if test="HDID != null">#{HDID},</if>
- <if test="HDBT != null">#{HDBT},</if>
- <if test="YWLSH != null">#{YWLSH},</if>
- <if test="HDKSSJ != null">#{HDKSSJ},</if>
- <if test="HDJSSJ != null">#{HDJSSJ},</if>
- <if test="HDLB != null">#{HDLB},</if>
- <if test="HDFQR != null">#{HDFQR},</if>
- <if test="JBR != null">#{JBR},</if>
- <if test="JBSJ != null">#{JBSJ},</if>
- <if test="SPR != null">#{SPR},</if>
- <if test="YHZH != null">#{YHZH},</if>
- </trim>
- )
- </insert>
- <!-- DEMO_HDXX 修改 -->
- <update id="DEMO_HDXX_U" parameterType="hashmap">
- update DEMO_HDXX
- set
- SPSJ= #{SPSJ},SPBZ= #{SPBZ},BZ= #{BZ},
- HDID= #{HDID},HDBT= #{HDBT},YWLSH= #{YWLSH},HDKSSJ= #{HDKSSJ},
- HDJSSJ= #{HDJSSJ},HDLB= #{HDLB},HDFQR= #{HDFQR},JBR= #{JBR},
- JBSJ= #{JBSJ},SPR= #{SPR}
- where
- HDID = #{HDID}
- </update>
- <!-- DEMO_HDXX 选择修改 -->
- <update id="DEMO_HDXX_US" parameterType="hashmap">
- update DEMO_HDXX
- set
- <trim suffixOverrides=",">
- <if test="SPSJ != null">SPSJ=#{SPSJ},</if>
- <if test="SPBZ != null">SPBZ=#{SPBZ},</if>
- <if test="BZ != null">BZ=#{BZ},</if>
- <if test="HDID != null">HDID=#{HDID},</if>
- <if test="HDBT != null">HDBT=#{HDBT},</if>
- <if test="YWLSH != null">YWLSH=#{YWLSH},</if>
- <if test="HDKSSJ != null">HDKSSJ=#{HDKSSJ},</if>
- <if test="HDJSSJ != null">HDJSSJ=#{HDJSSJ},</if>
- <if test="HDLB != null">HDLB=#{HDLB},</if>
- <if test="HDFQR != null">HDFQR=#{HDFQR},</if>
- <if test="JBR != null">JBR=#{JBR},</if>
- <if test="JBSJ != null">JBSJ=#{JBSJ},</if>
- <if test="SPR != null">SPR=#{SPR},</if>
- <if test="YHZH != null">YHZH=#{YHZH},</if>
- </trim>
- where
- HDID = #{HDID}
- </update>
- <!-- DEMO_HDXX 删除 -->
- <delete id="DEMO_HDXX_D" parameterType="hashmap">
- delete from DEMO_HDXX
- <where>
- HDID = #{HDID}
- </where>
- </delete>
- </mapper>
|