<?xml version="1.0" encoding="gbk" standalone="no"?>
<!DOCTYPE sqlMap PUBLIC "-//iBATIS.com//DTD SQL Map 2.0//EN" "http://ibatis.apache.org/dtd/sql-map-2.dtd">
<sqlMap namespace="" >
<!-- 	<typeAlias alias="Nhywjtjzwxxbbean" type="cn.vp.XXX.model.NhywjtjzwxxbBean"/> -->	<typeAlias alias="Nhywjtjzwxxb" type="cn.im.nhywjtjzwxxb.NhywjtjzwxxbBean"/>
	
	<sql id="condition_Nhywjtjzwxxb">
		where 1=1
		<isNotEmpty prepend='AND' property='LIKExh'>
			(xh like '%$LIKExh$%'   )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='xh'>
			(xh = #xh#  )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='LIKEjzwlx'>
			(jzwlx like '%$LIKEjzwlx$%'  )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='jzwlx'>
			(jzwlx = #jzwlx# )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='LIKEjzwmc'>
			(jzwmc like '%$LIKEjzwmc$%'  )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='jzwmc'>
			(jzwmc = #jzwmc# )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='LIKEjzwbh'>
			(jzwbh like '%$LIKEjzwbh$%'  )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='jzwbh'>
			(jzwbh = #jzwbh# )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='LIKEjzwqy'>
			(jzwqy like '%$LIKEjzwqy$%'  )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='jzwqy'>
			(jzwqy = #jzwqy# )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='LIKEjzwxz'>
			(jzwxz like '%$LIKEjzwxz$%'  )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='jzwxz'>
			(jzwxz = #jzwxz# )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='LIKElxr'>
			(lxr like '%$LIKElxr$%'  )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='lxr'>
			(lxr = #lxr# )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='LIKElxrdh'>
			(lxrdh like '%$LIKElxrdh$%'  )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='lxrdh'>
			(lxrdh = #lxrdh# )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='LIKElxrsj'>
			(lxrsj like '%$LIKElxrsj$%'  )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='lxrsj'>
			(lxrsj = #lxrsj# )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='LIKEjzwtp1'>
			(jzwtp1 like '%$LIKEjzwtp1$%'  )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='jzwtp1'>
			(jzwtp1 = #jzwtp1# )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='LIKEjzwtp2'>
			(jzwtp2 like '%$LIKEjzwtp2$%'  )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='jzwtp2'>
			(jzwtp2 = #jzwtp2# )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='LIKEjd'>
			(jd like '%$LIKEjd$%'  )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='jd'>
			(jd = #jd# )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='LIKEwd'>
			(wd like '%$LIKEwd$%'  )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='wd'>
			(wd = #wd# )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='LIKEjj'>
			(jj like '%$LIKEjj$%'  )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='jj'>
			(jj = #jj# )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='LIKEcjry'>
			(cjry like '%$LIKEcjry$%'  )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='cjry'>
			(cjry = #cjry# )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='LIKEcjrq'>
			(cjrq like '%$LIKEcjrq$%'  )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='cjrq'>
			(cjrq = #cjrq# )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='LIKExgry'>
			(xgry like '%$LIKExgry$%'  )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='xgry'>
			(xgry = #xgry# )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='LIKExgrq'>
			(xgrq like '%$LIKExgrq$%'  )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='xgrq'>
			(xgrq = #xgrq# )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='LIKEbz'>
			(bz like '%$LIKEbz$%'  )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='bz'>
			(bz = #bz# )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='LIKEkz1'>
			(kz1 like '%$LIKEkz1$%'  )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='kz1'>
			(kz1 = #kz1# )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='LIKEkz2'>
			(kz2 like '%$LIKEkz2$%'  )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='kz2'>
			(kz2 = #kz2# )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='LIKEkz3'>
			(kz3 like '%$LIKEkz3$%'  )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='kz3'>
			(kz3 = #kz3# )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='LIKEkz4'>
			(kz4 like '%$LIKEkz4$%'  )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='kz4'>
			(kz4 = #kz4# )
		</isNotEmpty>
		<isNotEmpty property='tableparam'>
			$tableparam$
		</isNotEmpty>
		<isNotEmpty property='order'>
			$order$
		</isNotEmpty>
	</sql>
	
	<!-- add object -->
	<insert id="insert_Nhywjtjzwxxb" parameterClass="java.util.Map">
		insert into 
		nhywjtjzwxxb(
		<dynamic prepend=" ">  
			<isNotEmpty prepend=',' property='xh'>xh</isNotEmpty>
			<isNotEmpty prepend=',' property='jzwlx'>jzwlx</isNotEmpty>
			<isNotEmpty prepend=',' property='jzwmc'>jzwmc</isNotEmpty>
			<isNotEmpty prepend=',' property='jzwbh'>jzwbh</isNotEmpty>
			<isNotEmpty prepend=',' property='jzwqy'>jzwqy</isNotEmpty>
			<isNotEmpty prepend=',' property='jzwxz'>jzwxz</isNotEmpty>
			<isNotEmpty prepend=',' property='lxr'>lxr</isNotEmpty>
			<isNotEmpty prepend=',' property='lxrdh'>lxrdh</isNotEmpty>
			<isNotEmpty prepend=',' property='lxrsj'>lxrsj</isNotEmpty>
			<isNotEmpty prepend=',' property='jzwtp1'>jzwtp1</isNotEmpty>
			<isNotEmpty prepend=',' property='jzwtp2'>jzwtp2</isNotEmpty>
			<isNotEmpty prepend=',' property='jd'>jd</isNotEmpty>
			<isNotEmpty prepend=',' property='wd'>wd</isNotEmpty>
			<isNotEmpty prepend=',' property='jj'>jj</isNotEmpty>
			<isNotEmpty prepend=',' property='cjry'>cjry</isNotEmpty>
			<isNotEmpty prepend=',' property='cjrq'>cjrq</isNotEmpty>
			<isNotEmpty prepend=',' property='xgry'>xgry</isNotEmpty>
			<isNotEmpty prepend=',' property='xgrq'>xgrq</isNotEmpty>
			<isNotEmpty prepend=',' property='bz'>bz</isNotEmpty>
			<isNotEmpty prepend=',' property='kz1'>kz1</isNotEmpty>
			<isNotEmpty prepend=',' property='kz2'>kz2</isNotEmpty>
			<isNotEmpty prepend=',' property='kz3'>kz3</isNotEmpty>
			<isNotEmpty prepend=',' property='kz4'>kz4</isNotEmpty>

		</dynamic>  
	    <![CDATA[ 
	        ) values ( 
	    ]]>  
	     <dynamic prepend=" "> 
			<isNotEmpty prepend=',' property='xh'>#xh#</isNotEmpty>
			<isNotEmpty prepend=',' property='jzwlx'>#jzwlx#</isNotEmpty>
			<isNotEmpty prepend=',' property='jzwmc'>#jzwmc#</isNotEmpty>
			<isNotEmpty prepend=',' property='jzwbh'>#jzwbh#</isNotEmpty>
			<isNotEmpty prepend=',' property='jzwqy'>#jzwqy#</isNotEmpty>
			<isNotEmpty prepend=',' property='jzwxz'>#jzwxz#</isNotEmpty>
			<isNotEmpty prepend=',' property='lxr'>#lxr#</isNotEmpty>
			<isNotEmpty prepend=',' property='lxrdh'>#lxrdh#</isNotEmpty>
			<isNotEmpty prepend=',' property='lxrsj'>#lxrsj#</isNotEmpty>
			<isNotEmpty prepend=',' property='jzwtp1'>#jzwtp1#</isNotEmpty>
			<isNotEmpty prepend=',' property='jzwtp2'>#jzwtp2#</isNotEmpty>
			<isNotEmpty prepend=',' property='jd'>#jd#</isNotEmpty>
			<isNotEmpty prepend=',' property='wd'>#wd#</isNotEmpty>
			<isNotEmpty prepend=',' property='jj'>#jj#</isNotEmpty>
			<isNotEmpty prepend=',' property='cjry'>#cjry#</isNotEmpty>
			<isNotEmpty prepend=',' property='cjrq'>#cjrq#</isNotEmpty>
			<isNotEmpty prepend=',' property='xgry'>#xgry#</isNotEmpty>
			<isNotEmpty prepend=',' property='xgrq'>#xgrq#</isNotEmpty>
			<isNotEmpty prepend=',' property='bz'>#bz#</isNotEmpty>
			<isNotEmpty prepend=',' property='kz1'>#kz1#</isNotEmpty>
			<isNotEmpty prepend=',' property='kz2'>#kz2#</isNotEmpty>
			<isNotEmpty prepend=',' property='kz3'>#kz3#</isNotEmpty>
			<isNotEmpty prepend=',' property='kz4'>#kz4#</isNotEmpty>

		 </dynamic>  
	    <![CDATA[ 
	        ) 
	    ]]> 
	</insert>
	
	<!-- edit object  -->
	<update id="update_Nhywjtjzwxxb" parameterClass="java.util.Map">
		update nhywjtjzwxxb 
		<dynamic prepend="set ">   
			
			<isNotEmpty prepend=',' property='jzwlx'>jzwlx=#jzwlx#</isNotEmpty>
			<isNotEmpty prepend=',' property='jzwmc'>jzwmc=#jzwmc#</isNotEmpty>
			<isNotEmpty prepend=',' property='jzwbh'>jzwbh=#jzwbh#</isNotEmpty>
			<isNotEmpty prepend=',' property='jzwqy'>jzwqy=#jzwqy#</isNotEmpty>
			<isNotEmpty prepend=',' property='jzwxz'>jzwxz=#jzwxz#</isNotEmpty>
			<isNotEmpty prepend=',' property='lxr'>lxr=#lxr#</isNotEmpty>
			<isNotEmpty prepend=',' property='lxrdh'>lxrdh=#lxrdh#</isNotEmpty>
			<isNotEmpty prepend=',' property='lxrsj'>lxrsj=#lxrsj#</isNotEmpty>
			<isNotEmpty prepend=',' property='jzwtp1'>jzwtp1=#jzwtp1#</isNotEmpty>
			<isNotEmpty prepend=',' property='jzwtp2'>jzwtp2=#jzwtp2#</isNotEmpty>
			<isNotEmpty prepend=',' property='jd'>jd=#jd#</isNotEmpty>
			<isNotEmpty prepend=',' property='wd'>wd=#wd#</isNotEmpty>
			<isNotEmpty prepend=',' property='jj'>jj=#jj#</isNotEmpty>
			<isNotEmpty prepend=',' property='cjry'>cjry=#cjry#</isNotEmpty>
			<isNotEmpty prepend=',' property='cjrq'>cjrq=#cjrq#</isNotEmpty>
			<isNotEmpty prepend=',' property='xgry'>xgry=#xgry#</isNotEmpty>
			<isNotEmpty prepend=',' property='xgrq'>xgrq=#xgrq#</isNotEmpty>
			<isNotEmpty prepend=',' property='bz'>bz=#bz#</isNotEmpty>
			<isNotEmpty prepend=',' property='kz1'>kz1=#kz1#</isNotEmpty>
			<isNotEmpty prepend=',' property='kz2'>kz2=#kz2#</isNotEmpty>
			<isNotEmpty prepend=',' property='kz3'>kz3=#kz3#</isNotEmpty>
			<isNotEmpty prepend=',' property='kz4'>kz4=#kz4#</isNotEmpty>

		</dynamic>
		where 1=1 
			<isNotEmpty prepend='AND' property='XGTJxh'> xh = #XGTJxh#</isNotEmpty>
			<isNotEmpty prepend='AND' property='XGTJjzwlx'> jzwlx = #XGTJjzwlx# </isNotEmpty>
			<isNotEmpty prepend='AND' property='XGTJjzwmc'> jzwmc = #XGTJjzwmc# </isNotEmpty>
			<isNotEmpty prepend='AND' property='XGTJjzwbh'> jzwbh = #XGTJjzwbh# </isNotEmpty>
			<isNotEmpty prepend='AND' property='XGTJjzwqy'> jzwqy = #XGTJjzwqy# </isNotEmpty>
			<isNotEmpty prepend='AND' property='XGTJjzwxz'> jzwxz = #XGTJjzwxz# </isNotEmpty>
			<isNotEmpty prepend='AND' property='XGTJlxr'> lxr = #XGTJlxr# </isNotEmpty>
			<isNotEmpty prepend='AND' property='XGTJlxrdh'> lxrdh = #XGTJlxrdh# </isNotEmpty>
			<isNotEmpty prepend='AND' property='XGTJlxrsj'> lxrsj = #XGTJlxrsj# </isNotEmpty>
			<isNotEmpty prepend='AND' property='XGTJjzwtp1'> jzwtp1 = #XGTJjzwtp1# </isNotEmpty>
			<isNotEmpty prepend='AND' property='XGTJjzwtp2'> jzwtp2 = #XGTJjzwtp2# </isNotEmpty>
			<isNotEmpty prepend='AND' property='XGTJjd'> jd = #XGTJjd# </isNotEmpty>
			<isNotEmpty prepend='AND' property='XGTJwd'> wd = #XGTJwd# </isNotEmpty>
			<isNotEmpty prepend='AND' property='XGTJjj'> jj = #XGTJjj# </isNotEmpty>
			<isNotEmpty prepend='AND' property='XGTJcjry'> cjry = #XGTJcjry# </isNotEmpty>
			<isNotEmpty prepend='AND' property='XGTJcjrq'> cjrq = #XGTJcjrq# </isNotEmpty>
			<isNotEmpty prepend='AND' property='XGTJxgry'> xgry = #XGTJxgry# </isNotEmpty>
			<isNotEmpty prepend='AND' property='XGTJxgrq'> xgrq = #XGTJxgrq# </isNotEmpty>
			<isNotEmpty prepend='AND' property='XGTJbz'> bz = #XGTJbz# </isNotEmpty>
			<isNotEmpty prepend='AND' property='XGTJkz1'> kz1 = #XGTJkz1# </isNotEmpty>
			<isNotEmpty prepend='AND' property='XGTJkz2'> kz2 = #XGTJkz2# </isNotEmpty>
			<isNotEmpty prepend='AND' property='XGTJkz3'> kz3 = #XGTJkz3# </isNotEmpty>
			<isNotEmpty prepend='AND' property='XGTJkz4'> kz4 = #XGTJkz4# </isNotEmpty>

	</update>

	<update id="updateJtjzwJdWdByXh"  parameterClass="java.util.HashMap">
		update nhywjtjzwxxb set  jd = #jd# , wd=#wd#, xgry=#xgry#,xgrq=#xgrq#  where 1=1 and xh = #xh#
	</update>

	<!-- delete object -->
	<delete id="delete_Nhywjtjzwxxb" parameterClass="java.util.Map">
		delete from nhywjtjzwxxb 
		<include refid="condition_Nhywjtjzwxxb"/>
	</delete>
	
	<!-- batch delete object -->
	<delete id="batch_delete_Nhywjtjzwxxb" parameterClass="java.util.Map">
		delete from nhywjtjzwxxb 
		where 1=1
			<isNotEmpty prepend='AND' property='keyword'>
			key  in (#keyword#)
			</isNotEmpty>
	</delete>
	
	<!-- query objects by page-->
	<select id="query_Nhywjtjzwxxb" resultClass="java.util.HashMap" parameterClass="java.util.Map">
		select 
			xh,jzwlx,(select csmc from xtcl where csdl='nhywJzwlx' and csdm=jzwlx) as jzwlxname,
			jzwmc,jzwbh,jzwqy,jzwxz,lxr,lxrdh,lxrsj,jzwtp1,jzwtp2,jd,wd,jj,cjry,cjrq,xgry,xgrq,bz,kz1,kz2,kz3,kz4
		from nhywjtjzwxxb 
		<include refid="condition_Nhywjtjzwxxb"/>		
	</select>

	<select id="listNhywjtjzwxxbByLoadMap" resultClass="java.util.HashMap" parameterClass="java.util.Map">
		select 
			xh,jzwlx,(select csmc from xtcl where csdl='nhywJzwlx' and csdm=jzwlx) as jzwlxname,
			jzwmc,jzwbh,jzwqy,jzwxz,lxr,lxrdh,lxrsj,jzwtp1,jzwtp2,jd,wd,jj,cjry,cjrq,xgry,xgrq,bz,kz1,kz2,kz3,kz4
		from nhywjtjzwxxb 
		<include refid="condition_Nhywjtjzwxxb"/>
	</select>
	
	<!-- query objects totalcount -->
	<select id="count_Nhywjtjzwxxb" resultClass="java.lang.Integer" parameterClass="java.util.Map">
		select count(*) from nhywjtjzwxxb 
		<include refid="condition_Nhywjtjzwxxb"/>			
	</select>
	
	<!-- batch add objects -->
	<insert id="batch_insert_Nhywjtjzwxxb" parameterClass="java.util.List">
	 	<![CDATA[
          INSERT
      	]]>
      	<iterate conjunction=" " > 
			into nhywjtjzwxxb(
			 <![CDATA[ 
				xh,jzwlx,jzwmc,jzwbh,jzwqy,jzwxz,lxr,lxrdh,lxrsj,jzwtp1,jzwtp2,jd,wd,jj,cjry,cjrq,xgry,xgrq,bz,kz1,kz2,kz3,kz4
			)values
			 ]]>  		 
			 <![CDATA[ 
				(
				#list[].xh#,#list[].jzwlx#,#list[].jzwmc#,#list[].jzwbh#,#list[].jzwqy#,#list[].jzwxz#,#list[].lxr#,#list[].lxrdh#,#list[].lxrsj#,#list[].jzwtp1#,#list[].jzwtp2#,#list[].jd#,#list[].wd#,#list[].jj#,#list[].cjry#,#list[].cjrq#,#list[].xgry#,#list[].xgrq#,#list[].bz#,#list[].kz1#,#list[].kz2#,#list[].kz3#,#list[].kz4#
				)
			]]>    
    	</iterate> 
	</insert>
</sqlMap>











