<?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="Lqjjfkdbean" type="cn.vp.XXX.model.LqjjfkdBean"/> -->	
		<typeAlias alias="Lqjjfkd" type="cn.im.lqzh.LqjjfkdBean"/>
	
	<sql id="condition_Lqjjfkd">
		where 1=1
		<isNotEmpty prepend='AND' property='LIKExh'>
			(xh like concat('%',#LIKExh# ,'%')   )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='xh'>
			(xh = #xh#  )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='LIKEjjdbh'>
			(jjdbh like concat('%',#LIKEjjdbh# ,'%')   )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='jjdbh'>
			(jjdbh = #jjdbh# )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='LIKEcjdbh'>
			(cjdbh like concat('%',#LIKEcjdbh# ,'%')   )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='cjdbh'>
			(cjdbh = #cjdbh# )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='LIKEfkdbh'>
			(fkdbh like concat('%',#LIKEfkdbh# ,'%')   )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='fkdbh'>
			(fkdbh = #fkdbh# )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='LIKEfkrybh'>
			(fkrybh like concat('%',#LIKEfkrybh# ,'%')   )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='fkrybh'>
			(fkrybh = #fkrybh# )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='LIKEfkrymc'>
			(fkrymc like concat('%',#LIKEfkrymc# ,'%')   )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='fkrymc'>
			(fkrymc = #fkrymc# )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='LIKEfkbmbh'>
			(fkbmbh like concat('%',#LIKEfkbmbh# ,'%')   )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='fkbmbh'>
			(fkbmbh = #fkbmbh# )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='LIKEfkbmmc'>
			(fkbmmc like concat('%',#LIKEfkbmmc# ,'%')   )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='fkbmmc'>
			(fkbmmc = #fkbmmc# )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='LIKEfknr'>
			(fknr like concat('%',#LIKEfknr# ,'%')   )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='fknr'>
			(fknr = #fknr# )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='LIKEfksj'>
			(fksj like concat('%',#LIKEfksj# ,'%')   )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='fksj'>
			(fksj = #fksj# )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='LIKEcjry'>
			(cjry like concat('%',#LIKEcjry# ,'%')   )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='cjry'>
			(cjry = #cjry# )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='LIKEcjrq'>
			(cjrq like concat('%',#LIKEcjrq# ,'%')   )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='cjrq'>
			(cjrq = #cjrq# )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='LIKExgry'>
			(xgry like concat('%',#LIKExgry# ,'%')   )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='xgry'>
			(xgry = #xgry# )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='LIKExgrq'>
			(xgrq like concat('%',#LIKExgrq# ,'%')   )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='xgrq'>
			(xgrq = #xgrq# )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='LIKEbz'>
			(bz like concat('%',#LIKEbz# ,'%')   )
		</isNotEmpty>
		<isNotEmpty prepend='AND' property='bz'>
			(bz = #bz# )
		</isNotEmpty>
		<isNotEmpty property='tableparam'>
			$tableparam$
		</isNotEmpty>
		<isNotEmpty property='order'>
			$order$
		</isNotEmpty>
	</sql>
	
	<!-- add object -->
	<insert id="insert_Lqjjfkd" parameterClass="java.util.Map">
		insert into 
		lqjjfkd(
		<dynamic prepend=" ">  
			<isNotEmpty prepend=',' property='xh'>xh</isNotEmpty>
			<isNotEmpty prepend=',' property='jjdbh'>jjdbh</isNotEmpty>
			<isNotEmpty prepend=',' property='cjdbh'>cjdbh</isNotEmpty>
			<isNotEmpty prepend=',' property='fkdbh'>fkdbh</isNotEmpty>
			<isNotEmpty prepend=',' property='fkrybh'>fkrybh</isNotEmpty>
			<isNotEmpty prepend=',' property='fkrymc'>fkrymc</isNotEmpty>
			<isNotEmpty prepend=',' property='fkbmbh'>fkbmbh</isNotEmpty>
			<isNotEmpty prepend=',' property='fkbmmc'>fkbmmc</isNotEmpty>
			<isNotEmpty prepend=',' property='fknr'>fknr</isNotEmpty>
			<isNotEmpty prepend=',' property='fksj'>fksj</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>

		</dynamic>  
	    <![CDATA[ 
	        ) values ( 
	    ]]>  
	     <dynamic prepend=" "> 
			<isNotEmpty prepend=',' property='xh'>#xh#</isNotEmpty>
			<isNotEmpty prepend=',' property='jjdbh'>#jjdbh#</isNotEmpty>
			<isNotEmpty prepend=',' property='cjdbh'>#cjdbh#</isNotEmpty>
			<isNotEmpty prepend=',' property='fkdbh'>#fkdbh#</isNotEmpty>
			<isNotEmpty prepend=',' property='fkrybh'>#fkrybh#</isNotEmpty>
			<isNotEmpty prepend=',' property='fkrymc'>#fkrymc#</isNotEmpty>
			<isNotEmpty prepend=',' property='fkbmbh'>#fkbmbh#</isNotEmpty>
			<isNotEmpty prepend=',' property='fkbmmc'>#fkbmmc#</isNotEmpty>
			<isNotEmpty prepend=',' property='fknr'>#fknr#</isNotEmpty>
			<isNotEmpty prepend=',' property='fksj'>#fksj#</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>

		 </dynamic>  
	    <![CDATA[ 
	        ) 
	    ]]> 
	</insert>
	
	<!-- edit object  -->
	<update id="update_Lqjjfkd" parameterClass="java.util.Map">
		update lqjjfkd 
		<dynamic prepend="set ">   
			
			<isNotEmpty prepend=',' property='jjdbh'>jjdbh=#jjdbh#</isNotEmpty>
			<isNotEmpty prepend=',' property='cjdbh'>cjdbh=#cjdbh#</isNotEmpty>
			<isNotEmpty prepend=',' property='fkdbh'>fkdbh=#fkdbh#</isNotEmpty>
			<isNotEmpty prepend=',' property='fkrybh'>fkrybh=#fkrybh#</isNotEmpty>
			<isNotEmpty prepend=',' property='fkrymc'>fkrymc=#fkrymc#</isNotEmpty>
			<isNotEmpty prepend=',' property='fkbmbh'>fkbmbh=#fkbmbh#</isNotEmpty>
			<isNotEmpty prepend=',' property='fkbmmc'>fkbmmc=#fkbmmc#</isNotEmpty>
			<isNotEmpty prepend=',' property='fknr'>fknr=#fknr#</isNotEmpty>
			<isNotEmpty prepend=',' property='fksj'>fksj=#fksj#</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>

		</dynamic>
		where 1=1 
			<isNotEmpty prepend='AND' property='XGTJxh'> xh = #XGTJxh#</isNotEmpty>
			<isNotEmpty prepend='AND' property='XGTJjjdbh'> jjdbh = #XGTJjjdbh# </isNotEmpty>
			<isNotEmpty prepend='AND' property='XGTJcjdbh'> cjdbh = #XGTJcjdbh# </isNotEmpty>
			<isNotEmpty prepend='AND' property='XGTJfkdbh'> fkdbh = #XGTJfkdbh# </isNotEmpty>
			<isNotEmpty prepend='AND' property='XGTJfkrybh'> fkrybh = #XGTJfkrybh# </isNotEmpty>
			<isNotEmpty prepend='AND' property='XGTJfkrymc'> fkrymc = #XGTJfkrymc# </isNotEmpty>
			<isNotEmpty prepend='AND' property='XGTJfkbmbh'> fkbmbh = #XGTJfkbmbh# </isNotEmpty>
			<isNotEmpty prepend='AND' property='XGTJfkbmmc'> fkbmmc = #XGTJfkbmmc# </isNotEmpty>
			<isNotEmpty prepend='AND' property='XGTJfknr'> fknr = #XGTJfknr# </isNotEmpty>
			<isNotEmpty prepend='AND' property='XGTJfksj'> fksj = #XGTJfksj# </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>

	</update>
	
	<!-- delete object -->
	<delete id="delete_Lqjjfkd" parameterClass="java.util.Map">
		delete from lqjjfkd 
		<include refid="condition_Lqjjfkd"/>
	</delete>
	
	<!-- query objects by page-->
	<select id="query_Lqjjfkd" resultClass="java.util.HashMap" parameterClass="java.util.Map">
		select 
			xh,jjdbh,cjdbh,fkdbh,fkrybh,fkrymc,fkbmbh,fkbmmc,fknr,fksj,cjry,cjrq,xgry,xgrq,bz
		from lqjjfkd 
		<include refid="condition_Lqjjfkd"/>
		<isNotEmpty prepend=' ' property='start'>
			limit #start# ,#limit#
		</isNotEmpty>
	</select>
	
	<!-- query objects totalcount -->
	<select id="count_Lqjjfkd" resultClass="java.lang.Integer" parameterClass="java.util.Map">
		select count(*) from lqjjfkd 
		<include refid="condition_Lqjjfkd"/>			
	</select>
	
</sqlMap>











