<insert id="insert_News" parameterClass="News">
<![CDATA[
insert into table(id, classtype, content)
values (#id#, #?????#, #content#)
]]>
</insert>其中“?????”的部分应该怎么写呢?试过写Class.Name是不行的,因为这个属性不是serialize的
解决方案 »
- 继承与实例化!!!!!!!
- Eclipse 工程导入到JBuilder中出现‘?????’乱码?
- 请大家帮我看看这个有关socket的程序,为什么客户端接收不到服务器端返回的信息?
- java 环境配置中的疑问
- 关于apache commons mail的问题 在线等!!!!!!!!
- 【求助】这是怎么回事?!?!?!?!?!??!?!?!?!?!?!?!?
- 我的路径怎样设置〉?
- 心情不好 连续散分~~2 :(
- 请问那位大虾玩过(星光汇讯系统)
- 请教各位大侠哪有JAVA或JAVA2的电子版手册下载?库—类—方法实在是太多了。
- sun.misc.BASE64Encoder 这个包在哪里找到
- 如何使多个timer在同时执行时不进行并发执行而是进入某个队列进行执行
<!DOCTYPE sqlMap PUBLIC "-//ibatis.apache.org//DTD SQL Map 2.0//EN" "http://ibatis.apache.org/dtd/sql-map-2.dtd" >
<sqlMap namespace="APP_A_PERSON" >
<typeAlias type="com.ccid.app.phms.pojo.Person" alias="personInfo" />
<resultMap id="personMap" class="personInfo" >
<result column="ID" property="id" jdbcType="DECIMAL" />
<result column="XM" property="xm" jdbcType="VARCHAR" />
<result column="SFZH" property="sfzh" jdbcType="VARCHAR" />
<result column="XB" property="xb" jdbcType="VARCHAR" />
<result column="CSRQ" property="csrq" jdbcType="VARCHAR" />
<result column="GJ" property="gj" jdbcType="VARCHAR" />
<result column="MZ" property="mz" jdbcType="VARCHAR" />
<result column="NL" property="nl" jdbcType="DECIMAL" />
<result column="HYZK" property="hyzk" jdbcType="VARCHAR" />
<result column="WHCD" property="whcd" jdbcType="VARCHAR" />
<result column="CSD" property="csd" jdbcType="VARCHAR" />
<result column="CJWH" property="cjwh" jdbcType="VARCHAR" />
<result column="DWBH" property="dwbh" jdbcType="VARCHAR" />
<result column="PTBH" property="ptbh" jdbcType="VARCHAR" />
<result column="XZZ" property="xzz" jdbcType="VARCHAR" />
<result column="CZLX" property="czlx" jdbcType="VARCHAR" />
<result column="LXRXM" property="lxrxm" jdbcType="VARCHAR" />
<result column="XQ" property="xq" jdbcType="VARCHAR" />
<result column="ZZDH" property="zzdh" jdbcType="VARCHAR" />
<result column="LXDH" property="lxdh" jdbcType="VARCHAR" />
<result column="LXRDH" property="lxrdh" jdbcType="VARCHAR" />
<result column="ZY" property="zy" jdbcType="VARCHAR" />
<result column="GZDW" property="gzdw" jdbcType="VARCHAR" />
<result column="JTBH" property="jtbh" jdbcType="VARCHAR" />
<result column="JDBH" property="jdbh" jdbcType="VARCHAR" />
<result column="JDXX" property="jdxx" jdbcType="VARCHAR" />
<result column="SQBH" property="sqbh" jdbcType="VARCHAR" />
<result column="HZGX" property="hzgx" jdbcType="VARCHAR" />
<result column="ZNS" property="zns" jdbcType="DECIMAL" />
<result column="FQXM" property="fqxm" jdbcType="VARCHAR" />
<result column="MQXM" property="mqxm" jdbcType="VARCHAR" />
<result column="YLFYZFFS" property="ylfyzffs" jdbcType="VARCHAR" />
<result column="YLZKH" property="ylzkh" jdbcType="VARCHAR" />
<result column="ZRYS" property="zrys" jdbcType="VARCHAR" />
<result column="MZTCDW" property="mztcdw" jdbcType="VARCHAR" />
<result column="YKTH" property="ykth" jdbcType="VARCHAR" />
<result column="CJ_USERID" property="cjUserid" jdbcType="DECIMAL" />
<result column="CJ_USERNAME" property="cjUsername" jdbcType="VARCHAR" />
<result column="CJ_TIME" property="cjTime" jdbcType="DATE" />
<result column="CJ_GROUPID" property="cjGroupid" jdbcType="DECIMAL" />
<result column="CJ_GROUPNAME" property="cjGroupname" jdbcType="VARCHAR" />
<result column="JDMC" property="jdmc" jdbcType="VARCHAR" />
<result column="SQMC" property="sqmc" jdbcType="VARCHAR" />
</resultMap>
<!-- 慢病高危人群 -->
<select id="getListOfMbgw" parameterClass="java.util.HashMap" resultMap="personMap">
select * from app_a_person where id in (
select distinct id from (select p.id from app_a_person p,app_a_gxy g,app_a_health h where (g.hid=p.id and h.pid=p.id) and
(
<isNotEmpty property="queryCondition">
<![CDATA[ $queryCondition$ ]]>
</isNotEmpty>
)
)
)
<isNotEmpty property="query">
<![CDATA[ $query$ ]]>
</isNotEmpty>
order by id desc
</select>
<select id="getCountOfMbgw" parameterClass="java.util.HashMap" resultClass="java.lang.Integer">
select count(*) from app_a_person where id in (
select distinct id from (select p.id from app_a_person p,app_a_gxy g,app_a_health h where (g.hid=p.id and h.pid=p.id) and
(
<isNotEmpty property="queryCondition">
<![CDATA[ $queryCondition$ ]]>
</isNotEmpty>
)
)
)
<isNotEmpty property="query">
<![CDATA[ $query$ ]]>
</isNotEmpty>
order by id desc
</select>
<!-- 高血压高危人群 -->
<select id="getListOfGxygw" parameterClass="java.util.HashMap" resultMap="personMap">
select * from app_a_person where id in(
select distinct id from(
select p.id from app_a_person p,app_a_randominfo r,app_a_health h,app_a_jzs j where (r.hzbh=p.dwbh or (h.pid=p.id and j.hid=p.id)) and
(
<isNotEmpty property="queryCondition">
<![CDATA[ $queryCondition$ ]]>
</isNotEmpty>
)
)
)
<isNotEmpty property="query">
<![CDATA[ $query$ ]]>
</isNotEmpty>
order by id desc
</select>
<select id="getCountOfGxygw" parameterClass="java.util.HashMap" resultClass="java.lang.Integer">
select count(*) from app_a_person where id in(
select distinct id from(
select p.id from app_a_person p,app_a_randominfo r,app_a_health h,app_a_jzs j where (r.hzbh=p.dwbh or (h.pid=p.id and j.hid=p.id)) and
(
<isNotEmpty property="queryCondition">
<![CDATA[ $queryCondition$ ]]>
</isNotEmpty>
)
)
)
<isNotEmpty property="query">
<![CDATA[ $query$ ]]>
</isNotEmpty>
order by id desc
</select>
<select id="getList" parameterClass="java.util.HashMap" resultMap="personMap">
select * from app_a_person where 1=1
<isNotEmpty property="query">
<![CDATA[ $query$ ]]>
</isNotEmpty>
order by id desc
</select>
<select id="getListCount" parameterClass="java.util.HashMap" resultClass="java.lang.Integer">
select count(*) from app_a_person where 1=1
<isNotEmpty property="query">
<![CDATA[ $query$ ]]>
</isNotEmpty>
</select>
<!--
1)没有随访信息,并且登记日期距今已超过90天
2)病人有一个或多个随访信息(无论高血压,糖尿病随访),查询最近一次随访日期(上一次)大于90天的记录
-->
<select id="getRemainList" parameterClass="java.util.HashMap" resultMap="personMap">
select * from app_a_person where dwbh not in (select hzbh from app_a_randominfo) and cj_time+90 <![CDATA[ < ]]> sysdate
union
select * from app_a_person where dwbh in (select hzbh from (select hzbh,max(sfrq) sfrq from app_a_randominfo where sfrq is not null
group by hzbh) where sfrq+90 <![CDATA[ < ]]> sysdate)
</select>
<select id="getRemainListCount" parameterClass="java.util.HashMap" resultClass="java.lang.Integer">
select count(*) from (
select * from app_a_person where dwbh not in (select hzbh from app_a_randominfo) and cj_time+90 <![CDATA[ < ]]> sysdate
union
select * from app_a_person where dwbh in (select hzbh from (select hzbh,max(sfrq) sfrq from app_a_randominfo where sfrq is not null
group by hzbh) where sfrq+90 <![CDATA[ < ]]> sysdate))
</select>
<delete id="delByIds" parameterClass="java.util.HashMap">
delete from app_a_person where id in ( $personIds$ )
</delete>
<select id="getCountBySfzh" parameterClass="java.util.HashMap" resultClass="java.lang.Integer">
select count(*) from app_a_person where sfzh= #sfzh#
</select>
<select id="getListByXm" parameterClass="java.util.HashMap" resultMap="personMap">
select * from app_a_person where xm= #xm#
</select>
<select id="getCountByXm" parameterClass="java.util.HashMap" resultClass="java.lang.Integer">
select count(*) from app_a_person where xm= #xm#
</select>
<!-- 根据ID查询信息 -->
<select id="getInfo" resultMap="personMap" parameterClass="personInfo" >
select * from APP_A_PERSON where ID = #id:DECIMAL#
</select>