<?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="Ptyhczrzbean" type="cn.vp.XXX.model.PtyhczrzBean"/> -->	
<!-- <typeAlias alias="Ptyhczrz" type="cn.bsystem.bsystem.PtyhczrzBean"/> -->
	
	<sql id="condition_Ptyhczrz">
		where 1=1
		<isNotEmpty prepend='AND' property='LIKEczrzbh'>
			(czrzbh like '%$LIKEczrzbh$%' )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='czrzbh'>
			(czrzbh = #czrzbh#  )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='LIKEkhbh'>
			(khbh like '%$LIKEkhbh$%')
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='khbh'>
			(khbh = #khbh# )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='LIKEyhbh'>
			(yhbh like '%$LIKEyhbh$%')
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='yhbh'>
			(yhbh = #yhbh# )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='LIKEyhzh'>
			(yhzh like '%$LIKEyhzh$%')
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='yhzh'>
			(yhzh = #yhzh# )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='LIKEyhmc'>
			(yhmc like '%$LIKEyhmc$%')
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='yhmc'>
			(yhmc = #yhmc# )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='LIKEkhdip'>
			(khdip like '%$LIKEkhdip$%')
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='khdip'>
			(khdip = #khdip# )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='LIKEczbm'>
			(czbm like '%$LIKEczbm$%')
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='czbm'>
			(czbm = #czbm# )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='LIKEczdx'>
			(czdx like '%$LIKEczdx$%')
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='czdx'>
			(czdx = #czdx# )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='LIKEczml'>
			(czml like '%$LIKEczml$%')
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='czml'>
			(czml = #czml# )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='LIKEms'>
			(ms like '%$LIKEms$%')
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='ms'>
			(ms = #ms# )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='LIKEczsj'>
			(czsj like '%$LIKEczsj$%')
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='czsj'>
			(czsj = #czsj# )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='LIKErzly'>
			(rzly like '%$LIKErzly$%')
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='rzly'>
			(rzly = #rzly# )
		</isNotEmpty>
		<isNotEmpty property='tableparam'>
			$tableparam$
		</isNotEmpty>
		<isNotEmpty property='order'>
			$order$
		</isNotEmpty>
	</sql>
	
	<!-- add object -->
	<insert id="insert_Ptyhczrz" parameterClass="java.util.Map">
		insert into 
		ptyhczrz(
		<dynamic prepend=" ">  
			<isNotEmpty prepend=',' property='czrzbh'>czrzbh</isNotEmpty>
			<isNotEmpty prepend=',' property='yhzh'>yhzh</isNotEmpty>
			<isNotEmpty prepend=',' property='yhbh'>yhbh</isNotEmpty>
			<isNotEmpty prepend=',' property='yhmc'>yhmc</isNotEmpty>
			<isNotEmpty prepend=',' property='khdip'>khdip</isNotEmpty>
			<isNotEmpty prepend=',' property='czbm'>czbm</isNotEmpty>
			<isNotEmpty prepend=',' property='czdx'>czdx</isNotEmpty>
			<isNotEmpty prepend=',' property='czml'>czml</isNotEmpty>
			<isNotEmpty prepend=',' property='ms'>ms</isNotEmpty>
			<isNotEmpty prepend=',' property='czsj'>czsj</isNotEmpty>
			<isNotEmpty prepend=',' property='rzly'>rzly</isNotEmpty>

		</dynamic>  
	    <![CDATA[ 
	        ) values ( 
	    ]]>  
	     <dynamic prepend=" "> 
			<isNotEmpty prepend=',' property='czrzbh'>#czrzbh#</isNotEmpty>
			<isNotEmpty prepend=',' property='yhzh'>#yhzh#</isNotEmpty>
			<isNotEmpty prepend=',' property='yhbh'>#yhbh#</isNotEmpty>
			<isNotEmpty prepend=',' property='yhmc'>#yhmc#</isNotEmpty>
			<isNotEmpty prepend=',' property='khdip'>#khdip#</isNotEmpty>
			<isNotEmpty prepend=',' property='czbm'>#czbm#</isNotEmpty>
			<isNotEmpty prepend=',' property='czdx'>#czdx#</isNotEmpty>
			<isNotEmpty prepend=',' property='czml'>#czml#</isNotEmpty>
			<isNotEmpty prepend=',' property='ms'>#ms#</isNotEmpty>
			<isNotEmpty prepend=',' property='czsj'>#czsj#</isNotEmpty>
			<isNotEmpty prepend=',' property='rzly'>#rzly#</isNotEmpty>

		 </dynamic>  
	    <![CDATA[ 
	        ) 
	    ]]> 
	</insert>
	
	<!-- edit object  -->
	<update id="update_Ptyhczrz" parameterClass="java.util.Map">
		update ptyhczrz 
		<dynamic prepend="set ">   
			
			<isNotEmpty prepend=',' property='khbh'>khbh=#khbh#</isNotEmpty>
			<isNotEmpty prepend=',' property='yhbh'>yhbh=#yhbh#</isNotEmpty>
			<isNotEmpty prepend=',' property='yhzh'>yhzh=#yhzh#</isNotEmpty>
			<isNotEmpty prepend=',' property='yhmc'>yhmc=#yhmc#</isNotEmpty>
			<isNotEmpty prepend=',' property='khdip'>khdip=#khdip#</isNotEmpty>
			<isNotEmpty prepend=',' property='czbm'>czbm=#czbm#</isNotEmpty>
			<isNotEmpty prepend=',' property='czdx'>czdx=#czdx#</isNotEmpty>
			<isNotEmpty prepend=',' property='czml'>czml=#czml#</isNotEmpty>
			<isNotEmpty prepend=',' property='ms'>ms=#ms#</isNotEmpty>
			<isNotEmpty prepend=',' property='czsj'>czsj=#czsj#</isNotEmpty>
			<isNotEmpty prepend=',' property='rzly'>rzly=#rzly#</isNotEmpty>

		</dynamic>
		where 1=1 
			<isNotEmpty prepend='AND' property='XGTJczrzbh'> czrzbh = #XGTJczrzbh#</isNotEmpty>
			<isNotEmpty prepend='AND' property='XGTJkhbh'> khbh = #XGTJkhbh# </isNotEmpty>
			<isNotEmpty prepend='AND' property='XGTJyhbh'> yhbh = #XGTJyhbh# </isNotEmpty>
			<isNotEmpty prepend='AND' property='XGTJyhzh'> yhzh = #XGTJyhzh# </isNotEmpty>
			<isNotEmpty prepend='AND' property='XGTJyhmc'> yhmc = #XGTJyhmc# </isNotEmpty>
			<isNotEmpty prepend='AND' property='XGTJkhdip'> khdip = #XGTJkhdip# </isNotEmpty>
			<isNotEmpty prepend='AND' property='XGTJczbm'> czbm = #XGTJczbm# </isNotEmpty>
			<isNotEmpty prepend='AND' property='XGTJczdx'> czdx = #XGTJczdx# </isNotEmpty>
			<isNotEmpty prepend='AND' property='XGTJczml'> czml = #XGTJczml# </isNotEmpty>
			<isNotEmpty prepend='AND' property='XGTJms'> ms = #XGTJms# </isNotEmpty>
			<isNotEmpty prepend='AND' property='XGTJczsj'> czsj = #XGTJczsj# </isNotEmpty>
			<isNotEmpty prepend='AND' property='XGTJrzly'> rzly = #XGTJrzly# </isNotEmpty>

	</update>
	
	<!-- delete object -->
	<delete id="delete_Ptyhczrz" parameterClass="java.util.Map">
		delete from ptyhczrz 
		<include refid="condition_Ptyhczrz"/>
	</delete>
	
	<!-- batch delete object -->
	<delete id="batch_delete_Ptyhczrz" parameterClass="java.util.Map">
		delete from ptyhczrz 
		where 1=1
			<isNotEmpty prepend='AND' property='keyword'>
			key  in (#keyword#)
			</isNotEmpty>
	</delete>
	
	<!-- query objects by page-->
	<select id="query_Ptyhczrz" resultClass="java.util.HashMap" parameterClass="java.util.Map">
		select 
			czrzbh,khbh,yhbh,yhzh,yhmc,khdip,czbm,czdx,czml,ms,czsj,rzly
		from ptyhczrz 
		<include refid="condition_Ptyhczrz"/>
		
	</select>
	
	<!-- query objects totalcount -->
	<select id="count_Ptyhczrz" resultClass="java.lang.Integer" parameterClass="java.util.Map">
		select count(*) from ptyhczrz 
		<include refid="condition_Ptyhczrz"/>			
	</select>
	
	<!-- batch add objects -->
	<insert id="batch_insert_Ptyhczrz" parameterClass="java.util.List">
	 	<![CDATA[
          INSERT
      	]]>
      	<iterate conjunction=" " > 
			into ptyhczrz(
			 <![CDATA[ 
				czrzbh,khbh,yhbh,yhzh,yhmc,khdip,czbm,czdx,czml,ms,czsj,rzly
			)values
			 ]]>  		 
			 <![CDATA[ 
				(
				#list[].czrzbh#,#list[].khbh#,#list[].yhbh#,#list[].yhzh#,#list[].yhmc#,#list[].khdip#,#list[].czbm#,#list[].czdx#,#list[].czml#,#list[].ms#,#list[].czsj#,#list[].rzly#
				)
			]]>    
    	</iterate> 
	</insert>
</sqlMap>











