You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
klintersrv/WEB-INF/conf/sysds_jimureport_normal_zys...

1469 lines
73 KiB

3 months ago
<?xml version="1.0" encoding="UTF-8"?>
<datasource>
<!-- 1 表示 sql语句dao 2表示存储过程dao 默认为sql语句dao-->
<dao id="normalZysrBaseinfoDao" log="true" type="1" memo="标准报表-报表通用的表头表尾信息Dao">
<sql>
select '' 开始日期,'' 结束日期,'' 制表人,'' 制表日期,'' 复核人,'' 医疗机构,'' 年度 from dual where 1=2
</sql>
<fields>
<f name="开始日期" type="93" />
<f name="结束日期" type="93" />
<f name="制表人" type="1" />
<f name="制表日期" type="93" />
<f name="复核人" type="1" />
<f name="医疗机构" type="1" />
<f name="年度" type="1" />
</fields>
</dao>
<dao id="normalZysrZybrfycxDao" log="true" type="1" memo="查询住院收入-在院病人费用查询Dao">
<sql>
select '' 项目名称,'' 上期余额,'' 本期借方,'' 本期贷方,'' 本期余额 from dual where 1=2
</sql>
<fields>
<f name="项目名称" type="1" />
<f name="上期余额" type="1" />
<f name="本期借方" type="1" />
<f name="本期贷方" type="1" />
<f name="本期余额" type="1" />
</fields>
</dao>
<dao id="normalZysrZybrfycxSqyeDao" log="true" type="1" memo="查询住院收入-在院病人费用查询-上期余额">
<sql><![CDATA[
select sum(SFXSJZFY) sqye,a.fyzl from HIS_SFZD_SFXMXB a left join HIS_SFZD_ZB b on a.ZDZBPKEY=b.pkey and a.JGID=b.JGID left join HIS_YZ_MXB c on a.YZMX=c.pkey and a.JGID=c.JGID left join HIS_JZ_BASEINFO d on c.jzpkey=d.pkey and c.JGID=d.JGID where a.JGID=? and (d.JZLX='Z' or d.JZLX='J' ) and d.JZZT='Z' and d.jjks like ? and a.JFRQ <? group by a.FYZL order by a.fyzl
]]></sql>
<fields>
<f name="sqye" type="4" />
<f name="fyzl" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
</parameter>
</dao>
<dao id="normalZysrZybrfycxBqjfDao" log="true" type="1" memo="查询住院收入-在院病人费用查询-本期借方">
<sql><![CDATA[
select sum(SFXSJZFY) bqjf,a.fyzl from HIS_SFZD_SFXMXB a left join HIS_SFZD_ZB b on a.ZDZBPKEY=b.pkey and a.JGID=b.JGID left join HIS_YZ_MXB c on a.YZMX=c.pkey and a.JGID=c.JGID left join HIS_JZ_BASEINFO d on c.jzpkey=d.pkey and c.JGID=d.JGID where a.JGID=? and (d.JZLX='Z' or d.JZLX='J' ) and d.JZZT='Z' and d.jjks like ? and a.JFRQ >=? and a.JFRQ <=? and (b.JSZT='0' or a.ZDZBPKEY='空')group by a.FYZL order by a.fyzl
]]></sql>
<fields>
<f name="bqjf" type="4" />
<f name="fyzl" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="normalZysrZybrfycxBqdfDao" log="true" type="1" memo="查询住院收入-在院病人费用查询-本期贷方">
<sql><![CDATA[
select sum(SFXSJZFY) bqdf,a.fyzl from HIS_SFZD_SFXMXB a left join HIS_SFZD_ZB b on a.ZDZBPKEY=b.pkey and a.JGID=b.JGID left join HIS_YZ_MXB c on a.YZMX=c.pkey and a.JGID=c.JGID left join HIS_JZ_BASEINFO d on c.jzpkey=d.pkey and c.JGID=d.JGID where a.JGID=? and (d.JZLX='Z' or d.JZLX='J' ) and d.JZZT='Z' and d.jjks like ? and a.JFRQ >=? and a.JFRQ <=? and b.JSZT !='0' group by a.FYZL order by a.fyzl
]]></sql>
<fields>
<f name="bqdf" type="4" />
<f name="fyzl" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="normalZysrZybrdetailfycxDao" log="true" type="1" memo="查询住院收入-在院病人详细费用查询Dao">
<sql>
select '' 科室,'' 就诊号,'' 住院号,'' 病人姓名,'' 上期余额,'' 本期借方,'' 本期贷方,'' 本期余额 from dual where 1=2
</sql>
<fields>
<f name="科室" type="1" />
<f name="就诊号" type="1" />
<f name="住院号" type="1" />
<f name="病人姓名" type="1" />
<f name="上期余额" type="1" />
<f name="本期借方" type="1" />
<f name="本期贷方" type="1" />
<f name="本期余额" type="1" />
</fields>
</dao>
<dao id="normalZysrZybrDetailfycxSqyeDao" log="true" type="1" memo="查询住院收入-在院病人详细费用查询-上期余额">
<sql><![CDATA[
select d.jjks,d.jzno,d.zyno,sum(SFXSJZFY) sqye,e.xm from HIS_SFZD_SFXMXB a left join HIS_SFZD_ZB b on a.ZDZBPKEY=b.pkey and a.JGID=b.JGID left join HIS_YZ_MXB c on a.YZMX=c.pkey and a.JGID=c.JGID left join HIS_JZ_BASEINFO d on c.jzpkey=d.pkey and c.JGID=d.JGID left join HIS_HZINFO e on d.hzpkey=e.pkey and d.JGID=e.JGID where a.JGID=? and (d.JZLX='Z' or d.JZLX='J' ) and d.JZZT='Z' and d.jjks like ? and a.JFRQ <? group by d.jjks,d.jzno,d.zyno,e.xm order by d.jjks,d.jzno
]]></sql>
<fields>
<f name="JJKS" type="12" />
<f name="JZNO" type="12" />
<f name="ZYNO" type="12" />
<f name="SQYE" type="4" />
<f name="XM" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
</parameter>
</dao>
<dao id="normalZysrZybrDetailfycxBqjfDao" log="true" type="1" memo="查询住院收入-在院病人详细费用查询-本期借方">
<sql><![CDATA[
select d.jjks,d.jzno,d.zyno,sum(SFXSJZFY) bqjf,e.xm from HIS_SFZD_SFXMXB a left join HIS_SFZD_ZB b on a.ZDZBPKEY=b.pkey and a.JGID=b.JGID left join HIS_YZ_MXB c on a.YZMX=c.pkey and a.JGID=c.JGID left join HIS_JZ_BASEINFO d on c.jzpkey=d.pkey and c.JGID=d.JGID left join HIS_HZINFO e on d.hzpkey=e.pkey and d.JGID=e.JGID where a.JGID=? and (d.JZLX='Z' or d.JZLX='J' ) and d.JZZT='Z' and d.jjks like ? and a.JFRQ >=? and a.JFRQ <=? and (b.JSZT='0' or a.ZDZBPKEY='空') group by d.jjks,d.jzno,d.zyno,e.xm order by d.jjks,d.jzno
]]></sql>
<fields>
<f name="JJKS" type="12" />
<f name="JZNO" type="12" />
<f name="ZYNO" type="12" />
<f name="bqjf" type="4" />
<f name="XM" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="normalZysrZybrDetailfycxBqdfDao" log="true" type="1" memo="查询住院收入-在院病人详细费用查询-本期贷方">
<sql><![CDATA[
select d.jjks,d.jzno,d.zyno,sum(SFXSJZFY) bqdf,e.xm from HIS_SFZD_SFXMXB a left join HIS_SFZD_ZB b on a.ZDZBPKEY=b.pkey and a.JGID=b.JGID left join HIS_YZ_MXB c on a.YZMX=c.pkey and a.JGID=c.JGID left join HIS_JZ_BASEINFO d on c.jzpkey=d.pkey and c.JGID=d.JGID left join HIS_HZINFO e on d.hzpkey=e.pkey and d.JGID=e.JGID where a.JGID=? and (d.JZLX='Z' or d.JZLX='J' ) and d.JZZT='Z' and d.jjks like ? and a.JFRQ >=? and a.JFRQ <=? and b.JSZT !='0' group by d.jjks,d.jzno,d.zyno,e.xm order by d.jjks,d.jzno
]]></sql>
<fields>
<f name="JJKS" type="12" />
<f name="JZNO" type="12" />
<f name="ZYNO" type="12" />
<f name="bqdf" type="4" />
<f name="XM" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="normalZysrZybrksfyShowDao" log="true" type="1" memo="查询住院收入-在院病人科室费用显示Dao">
<sql>
select '' 科室,'' 人次,'' 费用类别,'' 费用 from dual where 1=2
</sql>
<fields>
<f name="科室" type="1" />
<f name="人次" type="1" />
<f name="费用类别" type="1" />
<f name="费用" type="1" />
<!-- <f name="药费小计" type="1" />-->
<!-- <f name="药占比" type="1" />-->
</fields>
</dao>
<dao id="normalZysrZybrksfyByFyzlDao" log="true" type="1" memo="费用子类查询住院收入-在院病人科室费用">
<sql><![CDATA[
select sum(c.SFXSJZFY) fy,sfx.fyzl fylb,a.jjks from HIS_JZ_BASEINFO a left join HIS_YZ_MXB b on a.pkey=b.jzpkey and a.JGID=b.JGID left join HIS_SFZD_SFXMXB c on b.pkey=c.yzmx and b.JGID=c.JGID left join HIS_SFX sfx on c.sfx=sfx.bm and c.JGID=sfx.JGID where a.JGID=? and a.jjks like ? and (a.JZLX='Z' or a.JZLX='J' ) and a.jjrq >=? and a.jjrq <=? group by sfx.fyzl,a.jjks order by a.jjks,sfx.fyzl
]]></sql>
<fields>
<f name="fy" type="4" />
<f name="fylb" type="12" />
<f name="jjks" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="normalZysrZybrksfyByKjzlDao" log="true" type="1" memo="会计子类查询住院收入-在院病人科室费用">
<sql><![CDATA[
select sum(c.SFXSJZFY) fy,sfx.KJZFL fylb,a.jjks from HIS_JZ_BASEINFO a left join HIS_YZ_MXB b on a.pkey=b.jzpkey and a.JGID=b.JGID left join HIS_SFZD_SFXMXB c on b.pkey=c.yzmx and b.JGID=c.JGID left join HIS_SFX sfx on c.sfx=sfx.bm and c.JGID=sfx.JGID where a.JGID=? and a.jjks like ? and (a.JZLX='Z' or a.JZLX='J' ) and a.jjrq >=? and a.jjrq <=? group by sfx.KJZFL,a.jjks order by a.jjks,sfx.KJZFL
]]></sql>
<fields>
<f name="fy" type="4" />
<f name="fylb" type="12" />
<f name="jjks" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="normalZysrZybrksfyByHszlDao" log="true" type="1" memo="核算子类查询住院收入-在院病人科室费用">
<sql><![CDATA[
select sum(c.SFXSJZFY) fy,sfx.HSZFL fylb,a.jjks from HIS_JZ_BASEINFO a left join HIS_YZ_MXB b on a.pkey=b.jzpkey and a.JGID=b.JGID left join HIS_SFZD_SFXMXB c on b.pkey=c.yzmx and b.JGID=c.JGID left join HIS_SFX sfx on c.sfx=sfx.bm and c.JGID=sfx.JGID where a.JGID=? and a.jjks like ? and (a.JZLX='Z' or a.JZLX='J' ) and a.jjrq >=? and a.jjrq <=? group by sfx.HSZFL,a.jjks order by a.jjks,sfx.HSZFL
]]></sql>
<fields>
<f name="fy" type="4" />
<f name="fylb" type="12" />
<f name="jjks" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="normalZysrZybrksfyByBasyzlDao" log="true" type="1" memo="病案首页子类查询住院收入-在院病人科室费用">
<sql><![CDATA[
select sum(c.SFXSJZFY) fy,sfx.BASYFL fylb,a.jjks from HIS_JZ_BASEINFO a left join HIS_YZ_MXB b on a.pkey=b.jzpkey and a.JGID=b.JGID left join HIS_SFZD_SFXMXB c on b.pkey=c.yzmx and b.JGID=c.JGID left join HIS_SFX sfx on c.sfx=sfx.bm and c.JGID=sfx.JGID where a.JGID=? and a.jjks like ? and (a.JZLX='Z' or a.JZLX='J' ) and a.jjrq >=? and a.jjrq <=? group by sfx.BASYFL,a.jjks order by a.jjks,sfx.BASYFL
]]></sql>
<fields>
<f name="fy" type="4" />
<f name="fylb" type="12" />
<f name="jjks" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="normalZysrZybrksfyByFydlDao" log="true" type="1" memo="费用大类查询住院收入-在院病人科室费用">
<sql><![CDATA[
select sum(SFXSJZFY) fy,a.fydl fylb,d.jjks from HIS_SFZD_SFXMXB a left join HIS_SFZD_ZB b on a.ZDZBPKEY=b.pkey and a.JGID=b.JGID left join HIS_YZ_MXB c on a.YZMX=c.pkey and a.JGID=c.JGID left join HIS_JZ_BASEINFO d on c.jzpkey=d.pkey and c.JGID=d.JGID where a.JGID=? and (d.JZLX='Z' or d.JZLX='J' ) and d.JZZT='Z' and d.jjks like ? and a.JFRQ >=? and a.JFRQ <=? and (b.JSZT='0' or a.ZDZBPKEY='空')group by a.fydl,d.jjks order by d.jjks,a.fydl
]]></sql>
<fields>
<f name="fy" type="4" />
<f name="fylb" type="12" />
<f name="jjks" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="normalZysrZybrksfyByYpDao" log="true" type="1" memo="查询住院收入-在院病人科室药品费用">
<sql><![CDATA[
select sum(a.SFXSJZFY) ypfy,d.jjks from HIS_SFZD_SFXMXB a left join HIS_SFZD_ZB b on a.ZDZBPKEY=b.pkey and a.JGID=b.JGID left join HIS_YZ_MXB c on a.YZMX=c.pkey and a.JGID=c.JGID left join HIS_JZ_BASEINFO d on c.jzpkey=d.pkey and c.JGID=d.JGID left join HIS_SFX e on a.SFX=e.BM and a.JGID=e.JGID where a.JGID=? and (d.JZLX='Z' or d.JZLX='J' ) and d.JZZT='Z' and d.jjks like ? and a.JFRQ >=? and a.JFRQ <=? and (b.JSZT='0' or a.ZDZBPKEY='空') and e.GLLX='Y' group by d.jjks order by d.jjks
]]></sql>
<fields>
<f name="ypfy" type="4" />
<f name="jjks" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="normalZysrCyksrjfyShowDao" log="true" type="1" memo="查询住院收入-出院科室人均费用查询显示Dao">
<sql>
select '' 科室,'' 科室人次,'' 费用类别,'' 费用,'' 人均费用,'' 小计 from dual where 1=2
</sql>
<fields>
<f name="科室" type="1" />
<f name="科室人次" type="1" />
<f name="费用类别" type="1" />
<f name="费用" type="1" />
<f name="人均费用" type="1" />
<f name="小计" type="1" />
</fields>
</dao>
<dao id="normalZysrCyksrjfyByFyzlDao" log="true" type="1" memo="查询住院收入-费用子类出院科室人均费用查询">
<sql><![CDATA[
select sum(SFXSJZFY) fy,sfx.fyzl fylb,d.jjks from HIS_SFZD_SFXMXB a left join HIS_SFZD_ZB b on a.ZDZBPKEY=b.pkey and a.JGID=b.JGID left join HIS_YZ_MXB c on a.YZMX=c.pkey and a.JGID=c.JGID left join HIS_JZ_BASEINFO d on c.jzpkey=d.pkey and c.JGID=d.JGID left join HIS_SFX sfx on a.sfx=sfx.bm and a.JGID=sfx.JGID where a.JGID=? and (d.JZLX='Z' or d.JZLX='J' ) and d.JZZT='C' and nvl(d.jjks,'%') like ? and d.cyrq >=? and d.cyrq <=? and b.JSZT !='0' group by sfx.fyzl,d.jjks order by d.jjks,sfx.fyzl
]]></sql>
<fields>
<f name="fy" type="4" />
<f name="fylb" type="12" />
<f name="jjks" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="normalZysrCyksrjfyByKjzlDao" log="true" type="1" memo="查询住院收入-会计子类出院科室人均费用查询">
<sql><![CDATA[
select sum(SFXSJZFY) fy,sfx.KJZFL fylb,d.jjks from HIS_SFZD_SFXMXB a left join HIS_SFZD_ZB b on a.ZDZBPKEY=b.pkey and a.JGID=b.JGID left join HIS_YZ_MXB c on a.YZMX=c.pkey and a.JGID=c.JGID left join HIS_JZ_BASEINFO d on c.jzpkey=d.pkey and c.JGID=d.JGID left join HIS_SFX sfx on a.sfx=sfx.bm and a.JGID=sfx.JGID where a.JGID=? and (d.JZLX='Z' or d.JZLX='J' ) and d.JZZT='C' and nvl(d.jjks,'%') like ? and d.cyrq >=? and d.cyrq <=? and b.JSZT !='0' group by sfx.KJZFL,d.jjks order by d.jjks,sfx.KJZFL
]]></sql>
<fields>
<f name="fy" type="4" />
<f name="fylb" type="12" />
<f name="jjks" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="normalZysrCyksrjfyByHszlDao" log="true" type="1" memo="查询住院收入-核算子类出院科室人均费用查询">
<sql><![CDATA[
select sum(SFXSJZFY) fy,sfx.HSZFL fylb,d.jjks from HIS_SFZD_SFXMXB a left join HIS_SFZD_ZB b on a.ZDZBPKEY=b.pkey and a.JGID=b.JGID left join HIS_YZ_MXB c on a.YZMX=c.pkey and a.JGID=c.JGID left join HIS_JZ_BASEINFO d on c.jzpkey=d.pkey and c.JGID=d.JGID left join HIS_SFX sfx on a.sfx=sfx.bm and a.JGID=sfx.JGID where a.JGID=? and (d.JZLX='Z' or d.JZLX='J' ) and d.JZZT='C' and nvl(d.jjks,'%') like ? and d.cyrq >=? and d.cyrq <=? and b.JSZT !='0' group by sfx.HSZFL,d.jjks order by d.jjks,sfx.HSZFL
]]></sql>
<fields>
<f name="fy" type="4" />
<f name="fylb" type="12" />
<f name="jjks" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="normalZysrCyksrjfyByBasyzlDao" log="true" type="1" memo="查询住院收入-病案首页子类出院科室人均费用查询">
<sql><![CDATA[
select sum(SFXSJZFY) fy,sfx.BASYFL fylb,d.jjks from HIS_SFZD_SFXMXB a left join HIS_SFZD_ZB b on a.ZDZBPKEY=b.pkey and a.JGID=b.JGID left join HIS_YZ_MXB c on a.YZMX=c.pkey and a.JGID=c.JGID left join HIS_JZ_BASEINFO d on c.jzpkey=d.pkey and c.JGID=d.JGID left join HIS_SFX sfx on a.sfx=sfx.bm and a.JGID=sfx.JGID where a.JGID=? and (d.JZLX='Z' or d.JZLX='J' ) and d.JZZT='C' and nvl(d.jjks,'%') like ? and d.cyrq >=? and d.cyrq <=? and b.JSZT !='0' group by sfx.BASYFL,d.jjks order by d.jjks,sfx.BASYFL
]]></sql>
<fields>
<f name="fy" type="4" />
<f name="fylb" type="12" />
<f name="jjks" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="normalZysrCyksrjfyByFydlDao" log="true" type="1" memo="查询住院收入-费用大类出院科室人均费用查询">
<sql><![CDATA[
select sum(SFXSJZFY) fy,a.fydl fylb,d.jjks from HIS_SFZD_SFXMXB a left join HIS_SFZD_ZB b on a.ZDZBPKEY=b.pkey and a.JGID=b.JGID left join HIS_YZ_MXB c on a.YZMX=c.pkey and a.JGID=c.JGID left join HIS_JZ_BASEINFO d on c.jzpkey=d.pkey and c.JGID=d.JGID where a.JGID=? and (d.JZLX='Z' or d.JZLX='J' ) and d.JZZT='C' and nvl(d.jjks,'%') like ? and d.cyrq >=? and d.cyrq <=? and b.JSZT !='0' group by a.fydl,d.jjks order by d.jjks,a.fydl
]]></sql>
<fields>
<f name="fy" type="4" />
<f name="fylb" type="12" />
<f name="jjks" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="normalZysrCyksrcDao" log="true" type="1" memo="查询住院收入-出院科室人次dao">
<sql><![CDATA[
select count(*) rc,jjks from HIS_JZ_BASEINFO where JGID=? and nvl(jjks,'%') like ? and JZZT='C' and cyrq >=? and cyrq <= ? group by jjks
]]></sql>
<fields>
<f name="rc" type="4" />
<f name="jjks" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="normalCyksfyYzbShowDao" log="true" type="1" memo="查询住院收入-出院科室费用药占比显示Dao">
<sql>
select '' 科室,'' 费用类别,'' 费用 from dual where 1=2
</sql>
<fields>
<f name="科室" type="1" />
<f name="费用类别" type="1" />
<f name="费用" type="1" />
</fields>
</dao>
<dao id="normalZysrCybrksfyByFyzlDao" log="true" type="1" memo="查询住院收入-出院科室费用药占比-费用子类,查询时间按护士最终费用结算及出院时间为准">
<sql><![CDATA[
select sum(SFXSJZFY) fy,sfx.fyzl fylb,d.jjks from HIS_SFZD_SFXMXB a left join HIS_SFZD_ZB b on a.ZDZBPKEY=b.pkey and a.JGID=b.JGID left join HIS_YZ_MXB c on a.YZMX=c.pkey and a.JGID=c.JGID left join HIS_JZ_BASEINFO d on c.jzpkey=d.pkey and c.JGID=d.JGID left join HIS_SFX sfx on a.sfx=sfx.bm and a.JGID=sfx.JGID where a.JGID=? and (d.JZLX='Z' or d.JZLX='J' ) and d.JZZT='C' and b.JSZT=1 and nvl(d.jjks,'%') like ? and d.cyrq >=? and d.cyrq <=? group by sfx.FYZL,d.jjks order by d.jjks,sfx.fyzl
]]></sql>
<fields>
<f name="fy" type="4" />
<f name="fylb" type="12" />
<f name="jjks" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="normalZysrCybrksfyByKjzlDao" log="true" type="1" memo="查询住院收入-出院科室费用药占比-会计子类,查询时间按护士最终费用结算及出院时间为准">
<sql><![CDATA[
select sum(SFXSJZFY) fy,sfx.KJZFL fylb,d.jjks from HIS_SFZD_SFXMXB a left join HIS_SFZD_ZB b on a.ZDZBPKEY=b.pkey and a.JGID=b.JGID left join HIS_YZ_MXB c on a.YZMX=c.pkey and a.JGID=c.JGID left join HIS_JZ_BASEINFO d on c.jzpkey=d.pkey and c.JGID=d.JGID left join HIS_SFX sfx on a.sfx=sfx.bm and a.JGID=sfx.JGID where a.JGID=? and (d.JZLX='Z' or d.JZLX='J' ) and d.JZZT='C' and b.JSZT=1 and nvl(d.jjks,'%') like ? and d.cyrq >=? and d.cyrq <=? group by sfx.KJZFL,d.jjks order by d.jjks,sfx.KJZFL
]]></sql>
<fields>
<f name="fy" type="4" />
<f name="fylb" type="12" />
<f name="jjks" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="normalZysrCybrksfyByHszlDao" log="true" type="1" memo="查询住院收入-出院科室费用药占比-核算子类,查询时间按护士最终费用结算及出院时间为准">
<sql><![CDATA[
select sum(SFXSJZFY) fy,sfx.HSZFL fylb,d.jjks from HIS_SFZD_SFXMXB a left join HIS_SFZD_ZB b on a.ZDZBPKEY=b.pkey and a.JGID=b.JGID left join HIS_YZ_MXB c on a.YZMX=c.pkey and a.JGID=c.JGID left join HIS_JZ_BASEINFO d on c.jzpkey=d.pkey and c.JGID=d.JGID left join HIS_SFX sfx on a.sfx=sfx.bm and a.JGID=sfx.JGID where a.JGID=? and (d.JZLX='Z' or d.JZLX='J' ) and d.JZZT='C' and b.JSZT=1 and nvl(d.jjks,'%') like ? and d.cyrq >=? and d.cyrq <=? group by sfx.HSZFL,d.jjks order by d.jjks,sfx.HSZFL
]]></sql>
<fields>
<f name="fy" type="4" />
<f name="fylb" type="12" />
<f name="jjks" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="normalZysrCybrksfyByBasyzlDao" log="true" type="1" memo="查询住院收入-出院科室费用药占比-病案首页子类,查询时间按护士最终费用结算及出院时间为准">
<sql><![CDATA[
select sum(SFXSJZFY) fy,sfx.BASYFL fylb,d.jjks from HIS_SFZD_SFXMXB a left join HIS_SFZD_ZB b on a.ZDZBPKEY=b.pkey and a.JGID=b.JGID left join HIS_YZ_MXB c on a.YZMX=c.pkey and a.JGID=c.JGID left join HIS_JZ_BASEINFO d on c.jzpkey=d.pkey and c.JGID=d.JGID left join HIS_SFX sfx on a.sfx=sfx.bm and a.JGID=sfx.JGID where a.JGID=? and (d.JZLX='Z' or d.JZLX='J' ) and d.JZZT='C' and b.JSZT=1 and nvl(d.jjks,'%') like ? and d.cyrq >=? and d.cyrq <=? group by sfx.BASYFL,d.jjks order by d.jjks,sfx.BASYFL
]]></sql>
<fields>
<f name="fy" type="4" />
<f name="fylb" type="12" />
<f name="jjks" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="normalZysrCybrksfyByFydlDao" log="true" type="1" memo="查询住院收入-出院科室费用药占比-费用大类,查询时间按护士最终费用结算及出院时间为准">
<sql><![CDATA[
select sum(SFXSJZFY) fy,a.fydl fylb,d.jjks from HIS_SFZD_SFXMXB a left join HIS_SFZD_ZB b on a.ZDZBPKEY=b.pkey and a.JGID=b.JGID left join HIS_YZ_MXB c on a.YZMX=c.pkey and a.JGID=c.JGID left join HIS_JZ_BASEINFO d on c.jzpkey=d.pkey and c.JGID=d.JGID where a.JGID=? and (d.JZLX='Z' or d.JZLX='J' ) and d.JZZT='C' and b.JSZT=1 and nvl(d.jjks,'%') like ? and d.cyrq >=? and d.cyrq <=? group by a.FYDL,d.jjks order by d.jjks,a.fydl
]]></sql>
<fields>
<f name="fy" type="4" />
<f name="fylb" type="12" />
<f name="jjks" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="normalZysrCybrksfyByYpDao" log="true" type="1" memo="查询住院收入-出院科室药品费用,查询时间按护士最终费用结算及出院时间为准">
<sql><![CDATA[
select sum(a.SFXSJZFY) ypfy,d.jjks from HIS_SFZD_SFXMXB a left join HIS_SFZD_ZB b on a.ZDZBPKEY=b.pkey and a.JGID=b.JGID left join HIS_YZ_MXB c on a.YZMX=c.pkey and a.JGID=c.JGID left join HIS_JZ_BASEINFO d on c.jzpkey=d.pkey and c.JGID=d.JGID left join HIS_SFX e on a.SFX=e.BM and a.JGID=e.JGID where a.JGID=? and (d.JZLX='Z' or d.JZLX='J' ) and d.JZZT='C' and B.JSZT=1 and nvl(d.jjks,'%') like ? and d.cyrq >=? and d.cyrq <=? and e.GLLX='Y' group by d.jjks order by d.jjks
]]></sql>
<fields>
<f name="ypfy" type="4" />
<f name="jjks" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="normalCybrysyzbShowDao" log="true" type="1" memo="查询住院收入-出院科室医生药占比显示Dao">
<sql>
select '' 科室,'' 医生,'' 费用类别,'' 费用 from dual where 1=2
</sql>
<fields>
<f name="科室" type="1" />
<f name="医生" type="1" />
<f name="费用类别" type="1" />
<f name="费用" type="1" />
</fields>
</dao>
<dao id="normalZysrCybrysyzbByFyzlDao" log="true" type="1" memo="查询住院收入-出院科室医生药占比-费用子类,查询时间按护士最终费用结算及出院时间为准">
<sql><![CDATA[
select sum(SFXSJZFY) fy,sfx.fyzl fylb,d.jjks,d.jjys from HIS_SFZD_SFXMXB a left join HIS_SFZD_ZB b on a.ZDZBPKEY=b.pkey and a.JGID=b.JGID left join HIS_YZ_MXB c on a.YZMX=c.pkey and a.JGID=c.JGID left join HIS_JZ_BASEINFO d on c.jzpkey=d.pkey and c.JGID=d.JGID left join HIS_SFX sfx on a.sfx=sfx.bm and a.JGID=sfx.JGID where a.JGID=? and (d.JZLX='Z' or d.JZLX='J' )and d.JZZT='C' and B.JSZT=1 and nvl(d.jjks,'%') like ? and d.cyrq >=? and d.cyrq <=? group by sfx.fyzl,d.jjks,d.jjys order by d.jjks,d.jjys,sfx.fyzl
]]></sql>
<fields>
<f name="fy" type="4" />
<f name="fylb" type="12" />
<f name="jjks" type="12" />
<f name="jjys" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="normalZysrCybrysyzbByKjzlDao" log="true" type="1" memo="查询住院收入-出院科室医生药占比-会计子类,查询时间按护士最终费用结算及出院时间为准">
<sql><![CDATA[
select sum(SFXSJZFY) fy,sfx.KJZFL fylb,d.jjks,d.jjys from HIS_SFZD_SFXMXB a left join HIS_SFZD_ZB b on a.ZDZBPKEY=b.pkey and a.JGID=b.JGID left join HIS_YZ_MXB c on a.YZMX=c.pkey and a.JGID=c.JGID left join HIS_JZ_BASEINFO d on c.jzpkey=d.pkey and c.JGID=d.JGID left join HIS_SFX sfx on a.sfx=sfx.bm and a.JGID=sfx.JGID where a.JGID=? and (d.JZLX='Z' or d.JZLX='J' )and d.JZZT='C' and B.JSZT=1 and nvl(d.jjks,'%') like ? and d.cyrq >=? and d.cyrq <=? group by sfx.KJZFL,d.jjks,d.jjys order by d.jjks,d.jjys,sfx.KJZFL
]]></sql>
<fields>
<f name="fy" type="4" />
<f name="fylb" type="12" />
<f name="jjks" type="12" />
<f name="jjys" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="normalZysrCybrysyzbByHszlDao" log="true" type="1" memo="查询住院收入-出院科室医生药占比-核算子类,查询时间按护士最终费用结算及出院时间为准">
<sql><![CDATA[
select sum(SFXSJZFY) fy,sfx.HSZFL fylb,d.jjks,d.jjys from HIS_SFZD_SFXMXB a left join HIS_SFZD_ZB b on a.ZDZBPKEY=b.pkey and a.JGID=b.JGID left join HIS_YZ_MXB c on a.YZMX=c.pkey and a.JGID=c.JGID left join HIS_JZ_BASEINFO d on c.jzpkey=d.pkey and c.JGID=d.JGID left join HIS_SFX sfx on a.sfx=sfx.bm and a.JGID=sfx.JGID where a.JGID=? and (d.JZLX='Z' or d.JZLX='J' )and d.JZZT='C' and B.JSZT=1 and nvl(d.jjks,'%') like ? and d.cyrq >=? and d.cyrq <=? group by sfx.HSZFL,d.jjks,d.jjys order by d.jjks,d.jjys,sfx.HSZFL
]]></sql>
<fields>
<f name="fy" type="4" />
<f name="fylb" type="12" />
<f name="jjks" type="12" />
<f name="jjys" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="normalZysrCybrysyzbByBasyzlDao" log="true" type="1" memo="查询住院收入-出院科室医生药占比-病案首页子类,查询时间按护士最终费用结算及出院时间为准">
<sql><![CDATA[
select sum(SFXSJZFY) fy,sfx.BASYFL fylb,d.jjks,d.jjys from HIS_SFZD_SFXMXB a left join HIS_SFZD_ZB b on a.ZDZBPKEY=b.pkey and a.JGID=b.JGID left join HIS_YZ_MXB c on a.YZMX=c.pkey and a.JGID=c.JGID left join HIS_JZ_BASEINFO d on c.jzpkey=d.pkey and c.JGID=d.JGID left join HIS_SFX sfx on a.sfx=sfx.bm and a.JGID=sfx.JGID where a.JGID=? and (d.JZLX='Z' or d.JZLX='J' )and d.JZZT='C' and B.JSZT=1 and nvl(d.jjks,'%') like ? and d.cyrq >=? and d.cyrq <=? group by sfx.BASYFL,d.jjks,d.jjys order by d.jjks,d.jjys,sfx.BASYFL
]]></sql>
<fields>
<f name="fy" type="4" />
<f name="fylb" type="12" />
<f name="jjks" type="12" />
<f name="jjys" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="normalZysrCybrysyzbByFydlDao" log="true" type="1" memo="查询住院收入-出院科室医生药占比-费用大类,查询时间按护士最终费用结算及出院时间为准">
<sql><![CDATA[
select sum(SFXSJZFY) fy,a.fydl fylb,d.jjks,d.jjys from HIS_SFZD_SFXMXB a left join HIS_SFZD_ZB b on a.ZDZBPKEY=b.pkey and a.JGID=b.JGID left join HIS_YZ_MXB c on a.YZMX=c.pkey and a.JGID=c.JGID left join HIS_JZ_BASEINFO d on c.jzpkey=d.pkey and c.JGID=d.JGID where a.JGID=? and (d.JZLX='Z' or d.JZLX='J' )and d.JZZT='C' and B.JSZT=1 and nvl(d.jjks,'%') like ? and d.cyrq >=? and d.cyrq <=? group by a.fydl,d.jjks,d.jjys order by d.jjks,d.jjys,a.fydl
]]></sql>
<fields>
<f name="fy" type="4" />
<f name="fylb" type="12" />
<f name="jjks" type="12" />
<f name="jjys" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="normalZysrCybrysyzbByYpDao" log="true" type="1" memo="查询住院收入-出院科室医生药占比-出院科室药品费用,查询时间按护士最终费用结算及出院时间为准">
<sql><![CDATA[
select sum(a.SFXSJZFY) ypfy,d.jjks,d.jjys from HIS_SFZD_SFXMXB a left join HIS_SFZD_ZB b on a.ZDZBPKEY=b.pkey and a.JGID=b.JGID left join HIS_YZ_MXB c on a.YZMX=c.pkey and a.JGID=c.JGID left join HIS_JZ_BASEINFO d on c.jzpkey=d.pkey and c.JGID=d.JGID left join HIS_SFX e on a.SFX=e.BM and a.JGID=e.JGID where a.JGID=? and (d.JZLX='Z' or d.JZLX='J' ) and d.JZZT='C' and B.JSZT=1 and nvl(d.jjks,'%') like ? and d.cyrq >=? and d.cyrq <=? and e.GLLX='Y' group by d.jjks,d.jjys order by d.jjks,d.jjys
]]></sql>
<fields>
<f name="ypfy" type="4" />
<f name="jjks" type="12" />
<f name="jjys" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="normalZhuyuanBrYsyzbByYztimeShowDao" log="true" type="1" memo="查询住院收入-住院病人医生费用药占比(按医嘱日期)显示,包括在院和出院患者Dao">
<sql>
select '' 科室,'' 医生,'' 费用类别,'' 费用 from dual where 1=2
</sql>
<fields>
<f name="科室" type="1" />
<f name="医生" type="1" />
<f name="费用类别" type="1" />
<f name="费用" type="1" />
</fields>
</dao>
<dao id="normalZysrZhuyuanBrYsyzbByYztimeByFyzlDao" log="true" type="1" memo="查询住院收入-住院病人医生费用药占比(按医嘱日期)显示,包括在院和出院患者-费用子类,查询时间按医嘱计费日期为准">
<sql><![CDATA[
select sum(SFXSJZFY) fy,sfx.fyzl fylb,d.jjks,d.jjys from HIS_SFZD_SFXMXB a left join HIS_SFZD_ZB b on a.ZDZBPKEY=b.pkey and a.JGID=b.JGID left join HIS_YZ_MXB c on a.YZMX=c.pkey and a.JGID=c.JGID left join HIS_JZ_BASEINFO d on c.jzpkey=d.pkey and c.JGID=d.JGID left join HIS_SFX sfx on a.sfx=sfx.bm and a.JGID=sfx.JGID where a.JGID=? and (d.JZLX='Z' or d.JZLX='J' ) and (d.JZZT='Z' or d.JZZT='C') and nvl(d.jjks,'%') like ? and a.JFRQ >=? and a.JFRQ <=? group by sfx.fyzl,d.jjks,d.jjys order by d.jjks,d.jjys,sfx.fyzl
]]></sql>
<fields>
<f name="fy" type="4" />
<f name="fylb" type="12" />
<f name="jjks" type="12" />
<f name="jjys" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="normalZysrZhuyuanBrYsyzbByYztimeByKjzlDao" log="true" type="1" memo="查询住院收入-住院病人医生费用药占比(按医嘱日期)显示,包括在院和出院患者-会计子类,查询时间按医嘱计费日期为准">
<sql><![CDATA[
select sum(SFXSJZFY) fy,sfx.KJZFL fylb,d.jjks,d.jjys from HIS_SFZD_SFXMXB a left join HIS_SFZD_ZB b on a.ZDZBPKEY=b.pkey and a.JGID=b.JGID left join HIS_YZ_MXB c on a.YZMX=c.pkey and a.JGID=c.JGID left join HIS_JZ_BASEINFO d on c.jzpkey=d.pkey and c.JGID=d.JGID left join HIS_SFX sfx on a.sfx=sfx.bm and a.JGID=sfx.JGID where a.JGID=? and (d.JZLX='Z' or d.JZLX='J' ) and (d.JZZT='Z' or d.JZZT='C') and nvl(d.jjks,'%') like ? and a.JFRQ >=? and a.JFRQ <=? group by sfx.KJZFL,d.jjks,d.jjys order by d.jjks,d.jjys,sfx.KJZFL
]]></sql>
<fields>
<f name="fy" type="4" />
<f name="fylb" type="12" />
<f name="jjks" type="12" />
<f name="jjys" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="normalZysrZhuyuanBrYsyzbByYztimeByHszlDao" log="true" type="1" memo="查询住院收入-住院病人医生费用药占比(按医嘱日期)显示,包括在院和出院患者-核算子类,查询时间按医嘱计费日期为准">
<sql><![CDATA[
select sum(SFXSJZFY) fy,sfx.HSZFL fylb,d.jjks,d.jjys from HIS_SFZD_SFXMXB a left join HIS_SFZD_ZB b on a.ZDZBPKEY=b.pkey and a.JGID=b.JGID left join HIS_YZ_MXB c on a.YZMX=c.pkey and a.JGID=c.JGID left join HIS_JZ_BASEINFO d on c.jzpkey=d.pkey and c.JGID=d.JGID left join HIS_SFX sfx on a.sfx=sfx.bm and a.JGID=sfx.JGID where a.JGID=? and (d.JZLX='Z' or d.JZLX='J' ) and (d.JZZT='Z' or d.JZZT='C') and nvl(d.jjks,'%') like ? and a.JFRQ >=? and a.JFRQ <=? group by sfx.HSZFL,d.jjks,d.jjys order by d.jjks,d.jjys,sfx.HSZFL
]]></sql>
<fields>
<f name="fy" type="4" />
<f name="fylb" type="12" />
<f name="jjks" type="12" />
<f name="jjys" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="normalZysrZhuyuanBrYsyzbByYztimeByBasyzlDao" log="true" type="1" memo="查询住院收入-住院病人医生费用药占比(按医嘱日期)显示,包括在院和出院患者-病案首页子类,查询时间按医嘱计费日期为准">
<sql><![CDATA[
select sum(SFXSJZFY) fy,sfx.BASYFL fylb,d.jjks,d.jjys from HIS_SFZD_SFXMXB a left join HIS_SFZD_ZB b on a.ZDZBPKEY=b.pkey and a.JGID=b.JGID left join HIS_YZ_MXB c on a.YZMX=c.pkey and a.JGID=c.JGID left join HIS_JZ_BASEINFO d on c.jzpkey=d.pkey and c.JGID=d.JGID left join HIS_SFX sfx on a.sfx=sfx.bm and a.JGID=sfx.JGID where a.JGID=? and (d.JZLX='Z' or d.JZLX='J' ) and (d.JZZT='Z' or d.JZZT='C') and nvl(d.jjks,'%') like ? and a.JFRQ >=? and a.JFRQ <=? group by sfx.BASYFL,d.jjks,d.jjys order by d.jjks,d.jjys,sfx.BASYFL
]]></sql>
<fields>
<f name="fy" type="4" />
<f name="fylb" type="12" />
<f name="jjks" type="12" />
<f name="jjys" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="normalZysrZhuyuanBrYsyzbByYztimeByFydlDao" log="true" type="1" memo="查询住院收入-住院病人医生费用药占比(按医嘱日期)显示,包括在院和出院患者-费用大类,查询时间按医嘱计费日期为准">
<sql><![CDATA[
select sum(SFXSJZFY) fy,a.fydl fylb,d.jjks,d.jjys from HIS_SFZD_SFXMXB a left join HIS_SFZD_ZB b on a.ZDZBPKEY=b.pkey and a.JGID=b.JGID left join HIS_YZ_MXB c on a.YZMX=c.pkey and a.JGID=c.JGID left join HIS_JZ_BASEINFO d on c.jzpkey=d.pkey and c.JGID=d.JGID where a.JGID=? and (d.JZLX='Z' or d.JZLX='J' ) and (d.JZZT='Z' or d.JZZT='C') and nvl(d.jjks,'%') like ? and a.JFRQ >=? and a.JFRQ <=? group by a.fydl,d.jjks,d.jjys order by d.jjks,d.jjys,a.fydl
]]></sql>
<fields>
<f name="fy" type="4" />
<f name="fylb" type="12" />
<f name="jjks" type="12" />
<f name="jjys" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="normalZhuyuanBrYsyzbByYztimeByYpDao" log="true" type="1" memo="查询住院收入-住院病人医生费用药占比(按医嘱日期)显示,包括在院和出院患者-费用大类-出院科室药品费用,查询时间按医嘱计费日期为准">
<sql><![CDATA[
select sum(a.SFXSJZFY) ypfy,d.jjks,d.jjys from HIS_SFZD_SFXMXB a left join HIS_SFZD_ZB b on a.ZDZBPKEY=b.pkey and a.JGID=b.JGID left join HIS_YZ_MXB c on a.YZMX=c.pkey and a.JGID=c.JGID left join HIS_JZ_BASEINFO d on c.jzpkey=d.pkey and c.JGID=d.JGID left join HIS_SFX e on a.SFX=e.BM and a.JGID=e.JGID where a.JGID=? and (d.JZLX='Z' or d.JZLX='J' ) and (d.JZZT='Z' or d.JZZT='C') and d.jjks like ? and a.JFRQ >=? and a.JFRQ <=? and e.GLLX='Y' group by d.jjks,d.jjys order by d.jjks,d.jjys
]]></sql>
<fields>
<f name="ypfy" type="4" />
<f name="jjks" type="12" />
<f name="jjys" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="normalZysrZhuyuanBrKdYsyzbByYztimeByFyzlDao" log="true" type="1" memo="查询住院收入-住院病人开单医生费用药占比(按医嘱日期)显示,包括在院和出院患者-费用子类,查询时间按医嘱计费日期为准">
<sql><![CDATA[
select sum(SFXSJZFY) fy,sfx.fyzl fylb,d.jjks,e.YZXZYS from HIS_SFZD_SFXMXB a left join HIS_SFZD_ZB b on a.ZDZBPKEY=b.pkey and a.JGID=b.JGID left join HIS_YZ_MXB e on a.YZMX=e.pkey and a.JGID=e.JGID left join HIS_JZ_BASEINFO d on e.jzpkey=d.pkey and e.JGID=d.JGID left join HIS_SFX sfx on a.sfx=sfx.bm and a.JGID=sfx.JGID where a.JGID=? and (d.JZLX='Z' or d.JZLX='J' ) and (d.JZZT='Z' or d.JZZT='C') and nvl(d.jjks,'%') like ? and a.JFRQ >=? and a.JFRQ <=? group by sfx.fyzl,d.jjks,e.YZXZYS order by d.jjks,e.YZXZYS,sfx.fyzl
]]></sql>
<fields>
<f name="fy" type="4" />
<f name="fylb" type="12" />
<f name="jjks" type="12" />
<f name="YZXZYS" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="normalZysrZhuyuanBrKdYsyzbByYztimeByKjzlDao" log="true" type="1" memo="查询住院收入-住院病人开单医生费用药占比(按医嘱日期)显示,包括在院和出院患者-会计子类,查询时间按医嘱计费日期为准">
<sql><![CDATA[
select sum(SFXSJZFY) fy,sfx.KJZFL fylb,d.jjks,e.YZXZYS from HIS_SFZD_SFXMXB a left join HIS_SFZD_ZB b on a.ZDZBPKEY=b.pkey and a.JGID=b.JGID left join HIS_YZ_MXB e on a.YZMX=e.pkey and a.JGID=e.JGID left join HIS_JZ_BASEINFO d on e.jzpkey=d.pkey and e.JGID=d.JGID left join HIS_SFX sfx on a.sfx=sfx.bm and a.JGID=sfx.JGID where a.JGID=? and (d.JZLX='Z' or d.JZLX='J' ) and (d.JZZT='Z' or d.JZZT='C') and nvl(d.jjks,'%') like ? and a.JFRQ >=? and a.JFRQ <=? group by sfx.KJZFL,d.jjks,e.YZXZYS order by d.jjks,e.YZXZYS,sfx.KJZFL
]]></sql>
<fields>
<f name="fy" type="4" />
<f name="fylb" type="12" />
<f name="jjks" type="12" />
<f name="YZXZYS" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="normalZysrZhuyuanBrKdYsyzbByYztimeByHszlDao" log="true" type="1" memo="查询住院收入-住院病人开单医生费用药占比(按医嘱日期)显示,包括在院和出院患者-核算子类,查询时间按医嘱计费日期为准">
<sql><![CDATA[
select sum(SFXSJZFY) fy,sfx.HSZFL fylb,d.jjks,e.YZXZYS from HIS_SFZD_SFXMXB a left join HIS_SFZD_ZB b on a.ZDZBPKEY=b.pkey and a.JGID=b.JGID left join HIS_YZ_MXB e on a.YZMX=e.pkey and a.JGID=e.JGID left join HIS_JZ_BASEINFO d on e.jzpkey=d.pkey and e.JGID=d.JGID left join HIS_SFX sfx on a.sfx=sfx.bm and a.JGID=sfx.JGID where a.JGID=? and (d.JZLX='Z' or d.JZLX='J' ) and (d.JZZT='Z' or d.JZZT='C') and nvl(d.jjks,'%') like ? and a.JFRQ >=? and a.JFRQ <=? group by sfx.HSZFL,d.jjks,e.YZXZYS order by d.jjks,e.YZXZYS,sfx.HSZFL
]]></sql>
<fields>
<f name="fy" type="4" />
<f name="fylb" type="12" />
<f name="jjks" type="12" />
<f name="YZXZYS" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="normalZysrZhuyuanBrKdYsyzbByYztimeByBasyzlDao" log="true" type="1" memo="查询住院收入-住院病人开单医生费用药占比(按医嘱日期)显示,包括在院和出院患者-病案首页子类,查询时间按医嘱计费日期为准">
<sql><![CDATA[
select sum(SFXSJZFY) fy,sfx.BASYFL fylb,d.jjks,e.YZXZYS from HIS_SFZD_SFXMXB a left join HIS_SFZD_ZB b on a.ZDZBPKEY=b.pkey and a.JGID=b.JGID left join HIS_YZ_MXB e on a.YZMX=e.pkey and a.JGID=e.JGID left join HIS_JZ_BASEINFO d on e.jzpkey=d.pkey and e.JGID=d.JGID left join HIS_SFX sfx on a.sfx=sfx.bm and a.JGID=sfx.JGID where a.JGID=? and (d.JZLX='Z' or d.JZLX='J' ) and (d.JZZT='Z' or d.JZZT='C') and nvl(d.jjks,'%') like ? and a.JFRQ >=? and a.JFRQ <=? group by sfx.BASYFL,d.jjks,e.YZXZYS order by d.jjks,e.YZXZYS,sfx.BASYFL
]]></sql>
<fields>
<f name="fy" type="4" />
<f name="fylb" type="12" />
<f name="jjks" type="12" />
<f name="YZXZYS" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="normalZysrZhuyuanBrKdYsyzbByYztimeByFydlDao" log="true" type="1" memo="查询住院收入-住院病人开单医生费用药占比(按医嘱日期)显示,包括在院和出院患者-费用大类,查询时间按医嘱计费日期为准">
<sql><![CDATA[
select sum(SFXSJZFY) fy,a.fydl fylb,d.jjks,e.YZXZYS from HIS_SFZD_SFXMXB a left join HIS_SFZD_ZB b on a.ZDZBPKEY=b.pkey and a.JGID=b.JGID left join HIS_YZ_MXB e on a.YZMX=e.pkey and a.JGID=e.JGID left join HIS_JZ_BASEINFO d on e.jzpkey=d.pkey and e.JGID=d.JGID where a.JGID=? and (d.JZLX='Z' or d.JZLX='J' ) and (d.JZZT='Z' or d.JZZT='C') and nvl(d.jjks,'%') like ? and a.JFRQ >=? and a.JFRQ <=? group by a.FYDL,d.jjks,e.YZXZYS order by d.jjks,e.YZXZYS,a.fydl
]]></sql>
<fields>
<f name="fy" type="4" />
<f name="fylb" type="12" />
<f name="jjks" type="12" />
<f name="YZXZYS" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="normalZhuyuanBrKdYsyzbByYztimeByYpDao" log="true" type="1" memo="查询住院收入-住院病人开单医生费用药占比(按医嘱日期)显示,包括在院和出院患者-费用大类-出院科室药品费用,查询时间按医嘱计费日期为准">
<sql><![CDATA[
select sum(a.SFXSJZFY) ypfy,d.jjks,e.YZXZYS from HIS_SFZD_SFXMXB a left join HIS_SFZD_ZB b on a.ZDZBPKEY=b.pkey and a.JGID=b.JGID left join HIS_YZ_MXB e on a.YZMX=e.pkey and a.JGID=e.JGID left join HIS_JZ_BASEINFO d on e.jzpkey=d.pkey and e.JGID=d.JGID left join HIS_SFX f on a.SFX=f.BM and a.JGID=f.JGID where a.JGID=? and (d.JZLX='Z' or d.JZLX='J' ) and (d.JZZT='Z' or d.JZZT='C') and d.jjks like ? and a.JFRQ >=? and a.JFRQ <=? and f.GLLX='Y' group by d.jjks,e.YZXZYS order by d.jjks,e.YZXZYS
]]></sql>
<fields>
<f name="ypfy" type="4" />
<f name="jjks" type="12" />
<f name="YZXZYS" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="normalZysrZybrjsksfyByFyzlDao" log="true" type="1" memo="费用子类查询住院收入-住院病人医嘱执行科室费用">
<sql><![CDATA[
select sum(SFXSJZFY) fy,sfx.fyzl fylb,c.YZZXKS jjks from HIS_SFZD_SFXMXB a left join HIS_SFZD_ZB b on a.ZDZBPKEY=b.pkey and a.JGID=b.JGID left join HIS_YZ_MXB c on a.YZMX=c.pkey and a.JGID=c.JGID left join HIS_JZ_BASEINFO d on c.jzpkey=d.pkey and c.JGID=d.JGID left join HIS_SFX sfx on a.sfx=sfx.bm and a.JGID=sfx.JGID where a.JGID=? and (d.JZLX='Z' or d.JZLX='J' ) and (d.JZZT='Z' or d.JZZT='C') and nvl(c.YZZXKS,'%') like ? and a.JFRQ >=? and a.JFRQ <=? group by sfx.fyzl,c.YZZXKS order by c.YZZXKS,sfx.fyzl
]]></sql>
<fields>
<f name="fy" type="4" />
<f name="fylb" type="12" />
<f name="jjks" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="normalZysrZybrjsksfyByKjzlDao" log="true" type="1" memo="会计子类查询住院收入-住院病人医嘱执行科室费用">
<sql><![CDATA[
select sum(SFXSJZFY) fy,sfx.KJZFL fylb,c.YZZXKS jjks from HIS_SFZD_SFXMXB a left join HIS_SFZD_ZB b on a.ZDZBPKEY=b.pkey and a.JGID=b.JGID left join HIS_YZ_MXB c on a.YZMX=c.pkey and a.JGID=c.JGID left join HIS_JZ_BASEINFO d on c.jzpkey=d.pkey and c.JGID=d.JGID left join HIS_SFX sfx on a.sfx=sfx.bm and a.JGID=sfx.JGID where a.JGID=? and (d.JZLX='Z' or d.JZLX='J' ) and (d.JZZT='Z' or d.JZZT='C') and nvl(c.YZZXKS,'%') like ? and a.JFRQ >=? and a.JFRQ <=? group by sfx.KJZFL,c.YZZXKS order by c.YZZXKS,sfx.KJZF
]]></sql>
<fields>
<f name="fy" type="4" />
<f name="fylb" type="12" />
<f name="jjks" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="normalZysrZybrjsksfyByHszlDao" log="true" type="1" memo="核算子类查询住院收入-住院病人医嘱执行科室费用">
<sql><![CDATA[
select sum(SFXSJZFY) fy,sfx.HSZFL fylb,c.YZZXKS jjks from HIS_SFZD_SFXMXB a left join HIS_SFZD_ZB b on a.ZDZBPKEY=b.pkey and a.JGID=b.JGID left join HIS_YZ_MXB c on a.YZMX=c.pkey and a.JGID=c.JGID left join HIS_JZ_BASEINFO d on c.jzpkey=d.pkey and c.JGID=d.JGID left join HIS_SFX sfx on a.sfx=sfx.bm and a.JGID=sfx.JGID where a.JGID=? and (d.JZLX='Z' or d.JZLX='J' ) and (d.JZZT='Z' or d.JZZT='C') and nvl(c.YZZXKS,'%') like ? and a.JFRQ >=? and a.JFRQ <=? group by sfx.HSZFL,c.YZZXKS order by c.YZZXKS,sfx.HSZFL
]]></sql>
<fields>
<f name="fy" type="4" />
<f name="fylb" type="12" />
<f name="jjks" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="normalZysrZybrjsksfyByBasyzlDao" log="true" type="1" memo="病案首页子类查询住院收入-住院病人医嘱执行科室费用">
<sql><![CDATA[
select sum(SFXSJZFY) fy,sfx.BASYFL fylb,c.YZZXKS jjks from HIS_SFZD_SFXMXB a left join HIS_SFZD_ZB b on a.ZDZBPKEY=b.pkey and a.JGID=b.JGID left join HIS_YZ_MXB c on a.YZMX=c.pkey and a.JGID=c.JGID left join HIS_JZ_BASEINFO d on c.jzpkey=d.pkey and c.JGID=d.JGID left join HIS_SFX sfx on a.sfx=sfx.bm and a.JGID=sfx.JGID where a.JGID=? and (d.JZLX='Z' or d.JZLX='J' ) and (d.JZZT='Z' or d.JZZT='C') and nvl(c.YZZXKS,'%') like ? and a.JFRQ >=? and a.JFRQ <=? group by sfx.BASYFL,c.YZZXKS order by c.YZZXKS,sfx.BASYFL
]]></sql>
<fields>
<f name="fy" type="4" />
<f name="fylb" type="12" />
<f name="jjks" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="normalZysrZybrjsksfyByFydlDao" log="true" type="1" memo="费用大类查询住院收入-住院病人医嘱执行科室费用">
<sql><![CDATA[
select sum(SFXSJZFY) fy,a.fydl fylb,c.YZZXKS jjks from HIS_SFZD_SFXMXB a left join HIS_SFZD_ZB b on a.ZDZBPKEY=b.pkey and a.JGID=b.JGID left join HIS_YZ_MXB c on a.YZMX=c.pkey and a.JGID=c.JGID left join HIS_JZ_BASEINFO d on c.jzpkey=d.pkey and c.JGID=d.JGID where a.JGID=? and (d.JZLX='Z' or d.JZLX='J' ) and (d.JZZT='Z' or d.JZZT='C') and nvl(c.YZZXKS,'%') like ? and a.JFRQ >=? and a.JFRQ <=? group by a.fydl,c.YZZXKS order by c.YZZXKS,a.fydl
]]></sql>
<fields>
<f name="fy" type="4" />
<f name="fylb" type="12" />
<f name="jjks" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="normalZhuyuanHzMxShowDao" log="true" type="1" memo="查询住院收入-住院患者列表显示Dao">
<sql>
select '' 姓名,'' 就诊号,'' 是否出院,'' 费用类别,'' 费用,'' 科室 from dual where 1=2
</sql>
<fields>
<f name="姓名" type="1" />
<f name="就诊号" type="1" />
<f name="是否出院" type="1" />
<f name="费用类别" type="1" />
<f name="费用" type="1" />
<f name="科室" type="1" />
</fields>
</dao>
<dao id="normalZhuyuanHzMxByFyzlDao" log="true" type="1" memo="查询住院收入-住院患者列表-费用子类,查询时间按患者就诊时间为准">
<sql><![CDATA[
select sum(c.SFXSJZFY) fy,sfx.fyzl fylb,a.pkey,a.hzpkey,a.zyno,a.ZYNUM,a.JZZT,a.jjks from HIS_JZ_BASEINFO a left join HIS_YZ_MXB b on a.pkey=b.jzpkey and a.JGID=b.JGID left join HIS_SFZD_SFXMXB c on b.pkey=c.yzmx and b.JGID=c.JGID left join HIS_SFX sfx on c.sfx=sfx.bm and c.JGID=sfx.JGID where a.JGID=? and (a.JZLX='Z' or a.JZLX='J' ) #select# and a.jjks like ? and a.jjrq >=? and a.jjrq <=? group by sfx.fyzl,a.pkey,a.hzpkey,a.zyno,a.ZYNUM,a.JZZT,a.jjks order by a.jjks,a.pkey,a.hzpkey,a.zyno,a.ZYNUM,sfx.fyzl,a.JZZT
]]></sql>
<fields>
<f name="FY" type="4" />
<f name="FYLB" type="12" />
<f name="PKEY" type="12" />
<f name="HZPKEY" type="12" />
<f name="ZYNO" type="12" />
<f name="ZYNUM" type="8" />
<f name="JZZT" type="12" />
<f name="jjks" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="normalZhuyuanHzMxByKjzlDao" log="true" type="1" memo="查询住院收入-住院患者列表-会计子类,查询时间按患者就诊时间为准">
<sql><![CDATA[
select sum(c.SFXSJZFY) fy,sfx.KJZFL fylb,a.pkey,a.hzpkey,a.zyno,a.ZYNUM,a.JZZT,a.jjks from HIS_JZ_BASEINFO a left join HIS_YZ_MXB b on a.pkey=b.jzpkey and a.JGID=b.JGID left join HIS_SFZD_SFXMXB c on b.pkey=c.yzmx and b.JGID=c.JGID left join HIS_SFX sfx on c.sfx=sfx.bm and c.JGID=sfx.JGID where a.JGID=? and (a.JZLX='Z' or a.JZLX='J' ) #select# and a.jjks like ? and a.jjrq >=? and a.jjrq <=? group by sfx.KJZFL,a.pkey,a.hzpkey,a.zyno,a.ZYNUM,a.JZZT,a.jjks order by a.jjks,a.pkey,a.hzpkey,a.zyno,a.ZYNUM,sfx.KJZFL,a.JZZT
]]></sql>
<fields>
<f name="FY" type="4" />
<f name="FYLB" type="12" />
<f name="PKEY" type="12" />
<f name="HZPKEY" type="12" />
<f name="ZYNO" type="12" />
<f name="ZYNUM" type="8" />
<f name="JZZT" type="12" />
<f name="jjks" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="normalZhuyuanHzMxByHszlDao" log="true" type="1" memo="查询住院收入-住院患者列表-核算子类,查询时间按患者就诊时间为准">
<sql><![CDATA[
select sum(c.SFXSJZFY) fy,sfx.HSZFL fylb,a.pkey,a.hzpkey,a.zyno,a.ZYNUM,a.JZZT,a.jjks from HIS_JZ_BASEINFO a left join HIS_YZ_MXB b on a.pkey=b.jzpkey and a.JGID=b.JGID left join HIS_SFZD_SFXMXB c on b.pkey=c.yzmx and b.JGID=c.JGID left join HIS_SFX sfx on c.sfx=sfx.bm and c.JGID=sfx.JGID where a.JGID=? and (a.JZLX='Z' or a.JZLX='J' ) #select# and a.jjks like ? and a.jjrq >=? and a.jjrq <=? group by sfx.HSZFL,a.pkey,a.hzpkey,a.zyno,a.ZYNUM,a.JZZT,a.jjks order by a.jjks,a.pkey,a.hzpkey,a.zyno,a.ZYNUM,sfx.HSZFL,a.JZZT
]]></sql>
<fields>
<f name="FY" type="4" />
<f name="FYLB" type="12" />
<f name="PKEY" type="12" />
<f name="HZPKEY" type="12" />
<f name="ZYNO" type="12" />
<f name="ZYNUM" type="8" />
<f name="JZZT" type="12" />
<f name="jjks" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="normalZhuyuanHzMxByBasyzlDao" log="true" type="1" memo="查询住院收入-住院患者列表-病案首页子类,查询时间按患者就诊时间为准">
<sql><![CDATA[
select sum(c.SFXSJZFY) fy,sfx.BASYFL fylb,a.pkey,a.hzpkey,a.zyno,a.ZYNUM,a.JZZT,a.jjks from HIS_JZ_BASEINFO a left join HIS_YZ_MXB b on a.pkey=b.jzpkey and a.JGID=b.JGID left join HIS_SFZD_SFXMXB c on b.pkey=c.yzmx and b.JGID=c.JGID left join HIS_SFX sfx on c.sfx=sfx.bm and c.JGID=sfx.JGID where a.JGID=? and (a.JZLX='Z' or a.JZLX='J' ) #select# and a.jjks like ? and a.jjrq >=? and a.jjrq <=? group by sfx.BASYFL,a.pkey,a.hzpkey,a.zyno,a.ZYNUM,a.JZZT,a.jjks order by a.jjks,a.pkey,a.hzpkey,a.zyno,a.ZYNUM,sfx.BASYFL,a.JZZT
]]></sql>
<fields>
<f name="FY" type="4" />
<f name="FYLB" type="12" />
<f name="PKEY" type="12" />
<f name="HZPKEY" type="12" />
<f name="ZYNO" type="12" />
<f name="ZYNUM" type="8" />
<f name="JZZT" type="12" />
<f name="jjks" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="normalZhuyuanHzMxByFydlDao" log="true" type="1" memo="查询住院收入-住院患者列表-费用大类,查询时间按患者就诊时间为准">
<sql><![CDATA[
select sum(SFXSJZFY) fy,a.fydl fylb,d.pkey,d.hzpkey,d.zyno,d.ZYNUM,d.JZZT,d.jjks from HIS_SFZD_SFXMXB a left join HIS_SFZD_ZB b on a.ZDZBPKEY=b.pkey and a.JGID=b.JGID left join HIS_YZ_MXB c on a.YZMX=c.pkey and a.JGID=c.JGID left join HIS_JZ_BASEINFO d on c.jzpkey=d.pkey and c.JGID=d.JGID where a.JGID=? and (d.JZLX='Z' or d.JZLX='J' ) #select# and d.jjks like ? and d.jjrq >=? and d.jjrq <=? group by d.pkey,a.FYDL,d.hzpkey,d.zyno,d.ZYNUM,d.JZZT,d.jjks order by d.jjks,d.pkey,d.hzpkey,d.zyno,d.ZYNUM,a.fydl,d.JZZT
]]></sql>
<fields>
<f name="FY" type="4" />
<f name="FYLB" type="12" />
<f name="PKEY" type="12" />
<f name="HZPKEY" type="12" />
<f name="ZYNO" type="12" />
<f name="ZYNUM" type="8" />
<f name="JZZT" type="12" />
<f name="jjks" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="normalZhuyuanHzMxByYpDao" log="true" type="1" memo="查询住院收入-住院患者列表-药品费用,查询时间按患者就诊时间为准">
<sql><![CDATA[
select sum(c.SFXSJZFY) ypfy,c.fydl fylb,a.pkey,a.hzpkey,a.zyno,a.ZYNUM,a.JZZT,a.jjks from HIS_JZ_BASEINFO a left join HIS_YZ_MXB b on a.pkey=b.jzpkey and a.JGID=b.JGID left join HIS_SFZD_SFXMXB c on b.pkey=c.yzmx and b.JGID=c.JGID left join HIS_SFX sfx on c.sfx=sfx.bm and c.JGID=sfx.JGID where a.JGID=? and (a.JZLX='Z' or a.JZLX='J' ) #select# and a.jjks like ? and a.jjrq >=? and a.jjrq <=? and sfx.GLLX='Y' group by c.fydl,a.pkey,a.hzpkey,a.zyno,a.ZYNUM,a.JZZT,a.jjks order by a.jjks,a.pkey,a.hzpkey,a.zyno,a.ZYNUM,c.fydl,a.JZZT
]]></sql>
<fields>
<f name="ypfy" type="4" />
<f name="FYLB" type="12" />
<f name="PKEY" type="12" />
<f name="HZPKEY" type="12" />
<f name="ZYNO" type="12" />
<f name="ZYNUM" type="8" />
<f name="JZZT" type="12" />
<f name="jjks" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="normalAllZysrZybrksfyByFyzlDao" log="true" type="1" memo="费用子类查询住院收入-住院病人科室费用">
<sql><![CDATA[
select sum(SFXSJZFY) fy,sfx.fyzl fylb,d.jjks from HIS_SFZD_SFXMXB a left join HIS_SFZD_ZB b on a.ZDZBPKEY=b.pkey and a.JGID=b.JGID left join HIS_YZ_MXB c on a.YZMX=c.pkey and a.JGID=c.JGID left join HIS_JZ_BASEINFO d on c.jzpkey=d.pkey and c.JGID=d.JGID left join HIS_SFX sfx on a.sfx=sfx.bm and a.JGID=sfx.JGID where a.JGID=? and (d.JZLX='Z' or d.JZLX='J' ) and (d.JZZT='Z' or d.JZZT='C') and nvl(d.jjks,'%') like ? and a.JFRQ >=? and a.JFRQ <=? group by sfx.fyzl,d.jjks order by d.jjks,sfx.fyzl
]]></sql>
<fields>
<f name="fy" type="4" />
<f name="fylb" type="12" />
<f name="jjks" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="normalAllZysrZybrksfyByKjzlDao" log="true" type="1" memo="会计子类查询住院收入-住院病人科室费用">
<sql><![CDATA[
select sum(SFXSJZFY) fy,sfx.KJZFL fylb,d.jjks from HIS_SFZD_SFXMXB a left join HIS_SFZD_ZB b on a.ZDZBPKEY=b.pkey and a.JGID=b.JGID left join HIS_YZ_MXB c on a.YZMX=c.pkey and a.JGID=c.JGID left join HIS_JZ_BASEINFO d on c.jzpkey=d.pkey and c.JGID=d.JGID left join HIS_SFX sfx on a.sfx=sfx.bm and a.JGID=sfx.JGID where a.JGID=? and (d.JZLX='Z' or d.JZLX='J' ) and (d.JZZT='Z' or d.JZZT='C') and nvl(d.jjks,'%') like ? and a.JFRQ >=? and a.JFRQ <=? group by sfx.KJZFL,d.jjks order by d.jjks,sfx.KJZF
]]></sql>
<fields>
<f name="fy" type="4" />
<f name="fylb" type="12" />
<f name="jjks" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="normalAllZysrZybrksfyByHszlDao" log="true" type="1" memo="核算子类查询住院收入-住院病人科室费用">
<sql><![CDATA[
select sum(SFXSJZFY) fy,sfx.HSZFL fylb,d.jjks from HIS_SFZD_SFXMXB a left join HIS_SFZD_ZB b on a.ZDZBPKEY=b.pkey and a.JGID=b.JGID left join HIS_YZ_MXB c on a.YZMX=c.pkey and a.JGID=c.JGID left join HIS_JZ_BASEINFO d on c.jzpkey=d.pkey and c.JGID=d.JGID left join HIS_SFX sfx on a.sfx=sfx.bm and a.JGID=sfx.JGID where a.JGID=? and (d.JZLX='Z' or d.JZLX='J' ) and (d.JZZT='Z' or d.JZZT='C') and nvl(d.jjks,'%') like ? and a.JFRQ >=? and a.JFRQ <=? group by sfx.HSZFL,d.jjks order by d.jjks,sfx.HSZFL
]]></sql>
<fields>
<f name="fy" type="4" />
<f name="fylb" type="12" />
<f name="jjks" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="normalAllZysrZybrksfyByBasyzlDao" log="true" type="1" memo="病案首页子类查询住院收入-住院病人科室费用">
<sql><![CDATA[
select sum(SFXSJZFY) fy,sfx.BASYFL fylb,d.jjks from HIS_SFZD_SFXMXB a left join HIS_SFZD_ZB b on a.ZDZBPKEY=b.pkey and a.JGID=b.JGID left join HIS_YZ_MXB c on a.YZMX=c.pkey and a.JGID=c.JGID left join HIS_JZ_BASEINFO d on c.jzpkey=d.pkey and c.JGID=d.JGID left join HIS_SFX sfx on a.sfx=sfx.bm and a.JGID=sfx.JGID where a.JGID=? and (d.JZLX='Z' or d.JZLX='J' ) and (d.JZZT='Z' or d.JZZT='C') and nvl(d.jjks,'%') like ? and a.JFRQ >=? and a.JFRQ <=? group by sfx.BASYFL,d.jjks order by d.jjks,sfx.BASYFL
]]></sql>
<fields>
<f name="fy" type="4" />
<f name="fylb" type="12" />
<f name="jjks" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="normalAllZysrYjsZybrksfyByFyzlDao" log="true" type="1" memo="费用子类查询住院收入-已结算住院病人科室费用">
<sql><![CDATA[
select sum(DET_ITEM_FEE_SUMAMT) fy,sfx.fyzl fylb,e.jjks
from HIS_MZJS_MZFPZB a
left join HIS_SFZD_ZB b on a.GLZDBPKEY=b.pkey and a.JGID=b.JGID
left join HIS_YB_DJ c on b.pkey=c.ZDZBPKEY and b.JGID=c.JGID
left join HIS_YB_JSB j on c.JGID=j.JGID and c.IPT_NO=j.IPT_NO and c.MDTRT_ID=j.MDTRT_ID
left join HIS_YB_SCMX d on d.MDTRT_ID=j.MDTRT_ID and d.JGID=j.JGID and d.SETL_ID=j.SETL_ID
left join HIS_JZ_BASEINFO e on b.jzpkey=e.pkey and b.JGID=e.JGID
left join HIS_SFX sfx on d.MEDINS_LIST_CODG=sfx.bm and d.JGID=sfx.JGID
where a.JGID=? and nvl(e.jjks,'%') like ? and e.jzlx='Z' and a.PJLX='ZS' and a.SFZT !='0' and c.djcxzt='0' and j.CXZT='0' and c.MDTRT_ID is not null and a.sfrq >=? and a.sfrq <=?
group by sfx.fyzl,e.jjks order by e.jjks,sfx.fyzl
]]></sql>
<fields>
<f name="fy" type="4" />
<f name="fylb" type="12" />
<f name="jjks" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="normalAllZysrYjsZybrksfyByKjzlDao" log="true" type="1" memo="会计子类查询住院收入-已结算住院病人科室费用">
<sql><![CDATA[
select sum(DET_ITEM_FEE_SUMAMT) fy,sfx.KJZFL fylb,e.jjks
from HIS_MZJS_MZFPZB a
left join HIS_SFZD_ZB b on a.GLZDBPKEY=b.pkey and a.JGID=b.JGID
left join HIS_YB_DJ c on b.pkey=c.ZDZBPKEY and b.JGID=c.JGID
left join HIS_YB_JSB j on c.JGID=j.JGID and c.IPT_NO=j.IPT_NO and c.MDTRT_ID=j.MDTRT_ID
left join HIS_YB_SCMX d on d.MDTRT_ID=j.MDTRT_ID and d.JGID=j.JGID and d.SETL_ID=j.SETL_ID
left join HIS_JZ_BASEINFO e on b.jzpkey=e.pkey and b.JGID=e.JGID
left join HIS_SFX sfx on d.MEDINS_LIST_CODG=sfx.bm and d.JGID=sfx.JGID
where a.JGID=? and nvl(e.jjks,'%') like ? and e.jzlx='Z' and a.PJLX='ZS' and a.SFZT !='0' and c.djcxzt='0' and j.CXZT='0' and c.MDTRT_ID is not null and a.sfrq >=? and a.sfrq <=?
group by sfx.KJZFL,e.jjks order by e.jjks,sfx.KJZFL
]]></sql>
<fields>
<f name="fy" type="4" />
<f name="fylb" type="12" />
<f name="jjks" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="normalAllZysrYjsZybrksfyByHszlDao" log="true" type="1" memo="核算子类查询住院收入-已结算住院病人科室费用">
<sql><![CDATA[
select sum(DET_ITEM_FEE_SUMAMT) fy,sfx.HSZFL fylb,e.jjks
from HIS_MZJS_MZFPZB a
left join HIS_SFZD_ZB b on a.GLZDBPKEY=b.pkey and a.JGID=b.JGID
left join HIS_YB_DJ c on b.pkey=c.ZDZBPKEY and b.JGID=c.JGID
left join HIS_YB_JSB j on c.JGID=j.JGID and c.IPT_NO=j.IPT_NO and c.MDTRT_ID=j.MDTRT_ID
left join HIS_YB_SCMX d on d.MDTRT_ID=j.MDTRT_ID and d.JGID=j.JGID and d.SETL_ID=j.SETL_ID
left join HIS_JZ_BASEINFO e on b.jzpkey=e.pkey and b.JGID=e.JGID
left join HIS_SFX sfx on d.MEDINS_LIST_CODG=sfx.bm and d.JGID=sfx.JGID
where a.JGID=? and nvl(e.jjks,'%') like ? and e.jzlx='Z' and a.PJLX='ZS' and a.SFZT !='0' and c.djcxzt='0' and j.CXZT='0' and c.MDTRT_ID is not null and a.sfrq >=? and a.sfrq <=?
group by sfx.HSZFL,e.jjks order by e.jjks,sfx.HSZFL
]]></sql>
<fields>
<f name="fy" type="4" />
<f name="fylb" type="12" />
<f name="jjks" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="normalAllZysrYjsZybrksfyByBasyzlDao" log="true" type="1" memo="病案首页子类查询住院收入-已结算住院病人科室费用">
<sql><![CDATA[
select sum(DET_ITEM_FEE_SUMAMT) fy,sfx.BASYFL fylb,e.jjks
from HIS_MZJS_MZFPZB a
left join HIS_SFZD_ZB b on a.GLZDBPKEY=b.pkey and a.JGID=b.JGID
left join HIS_YB_DJ c on b.pkey=c.ZDZBPKEY and b.JGID=c.JGID
left join HIS_YB_JSB j on c.JGID=j.JGID and c.IPT_NO=j.IPT_NO and c.MDTRT_ID=j.MDTRT_ID
left join HIS_YB_SCMX d on d.MDTRT_ID=j.MDTRT_ID and d.JGID=j.JGID and d.SETL_ID=j.SETL_ID
left join HIS_JZ_BASEINFO e on b.jzpkey=e.pkey and b.JGID=e.JGID
left join HIS_SFX sfx on d.MEDINS_LIST_CODG=sfx.bm and d.JGID=sfx.JGID
where a.JGID=? and nvl(e.jjks,'%') like ? and e.jzlx='Z' and a.PJLX='ZS' and a.SFZT !='0' and c.djcxzt='0' and j.CXZT='0' and c.MDTRT_ID is not null and a.sfrq >=? and a.sfrq <=?
group by sfx.BASYFL,e.jjks order by e.jjks,sfx.BASYFL
]]></sql>
<fields>
<f name="fy" type="4" />
<f name="fylb" type="12" />
<f name="jjks" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="normalAllZysrYjsZybrksRsDao" log="true" type="1" memo="结算人次-已结算住院病人">
<sql><![CDATA[
select count(*) rc,e.jjks
from HIS_MZJS_MZFPZB a
left join HIS_SFZD_ZB b on a.GLZDBPKEY=b.pkey and a.JGID=b.JGID
left join HIS_YB_DJ c on b.pkey=c.ZDZBPKEY and b.JGID=c.JGID
left join HIS_YB_JSB j on c.JGID=j.JGID and c.IPT_NO=j.IPT_NO and c.MDTRT_ID=j.MDTRT_ID
left join HIS_JZ_BASEINFO e on b.jzpkey=e.pkey and b.JGID=e.JGID
where a.JGID=? and nvl(e.jjks,'%') like ? and e.jzlx='Z' and a.PJLX='ZS' and a.SFZT !='0' and c.djcxzt='0' and j.CXZT='0' and a.sfrq >=? and a.sfrq <=?
group by e.jjks order by e.jjks
]]></sql>
<fields>
<f name="rc" type="4" />
<f name="jjks" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="ksgzltjShowDao" log="true" type="1" memo="科室工作量收入显示Dao">
<sql>
select '' 科室,'' 类别,'' 医生,'' 人次,'' 合计,'' 药品小计,'' 西药费,'' 成药费,'' 中药制剂,'' 草药费,'' 材料费,'' 输氧费,'' 检查小计,'' 胃镜费,'' CT费,'' DR费,'' 彩超费,'' 心电图费,'' 化验费,'' 中医体质辨识,'' 医务小计,'' 诊察费,'' 护理费,'' 治疗费,'' 床位费,'' 中医适宜技术,'' 手术费
,'' 麻醉费,'' 煎药费,'' 救护车费,'' 其他费 from dual where 1=2
</sql>
<fields>
<f name="科室" type="1" />
<f name="类别" type="1" />
<f name="医生" type="1" />
<f name="人次" type="1" />
<f name="合计" type="1" />
<f name="药品小计" type="1" />
<f name="西药费" type="1" />
<f name="成药费" type="1" />
<f name="中药制剂" type="1" />
<f name="草药费" type="1" />
<f name="材料费" type="1" />
<f name="输氧费" type="1" />
<f name="检查小计" type="1" />
<f name="胃镜费" type="1" />
<f name="CT费" type="1" />
<f name="DR费" type="1" />
<f name="彩超费" type="1" />
<f name="心电图费" type="1" />
<f name="化验费" type="1" />
<f name="中医体质辨识" type="1" />
<f name="医务小计" type="1" />
<f name="诊察费" type="1" />
<f name="护理费" type="1" />
<f name="治疗费" type="1" />
<f name="床位费" type="1" />
<f name="中医适宜技术" type="1" />
<f name="手术费" type="1" />
<f name="麻醉费" type="1" />
<f name="煎药费" type="1" />
<f name="救护车费" type="1" />
<f name="其他费" type="1" />
</fields>
</dao>
<dao id="ksgzltjZyDao" log="true" type="1" memo="科室工作量收入-住院">
<sql><![CDATA[
select sum(c.SFXSJZFY) fy,a.jjks,a.jjys YZXZYS,jgzdb.value4 from HIS_JZ_BASEINFO a left join HIS_YZ_MXB b on a.pkey=b.jzpkey and a.JGID=b.JGID left join HIS_SFZD_SFXMXB c on b.pkey=c.yzmx and b.JGID=c.JGID left join HIS_SFX sfx on c.sfx=sfx.bm and c.JGID=sfx.JGID left join MAIN_JGZDB jgzdb on sfx.fyzl=jgzdb.bh and sfx.JGID=jgzdb.JGID and jgzdb.JGZDLB_BH='Z00004' where a.JGID=? and (a.JZLX='Z' or a.JZLX='J' ) and nvl(a.jjks,'%') like ? and a.jjrq >=? and a.jjrq <=? group by jgzdb.value4,a.jjks,a.jjys order by a.jjks,a.jjys,jgzdb.value4
]]></sql>
<fields>
<f name="FY" type="4" />
<f name="JJKS" type="12" />
<f name="YZXZYS" type="12" />
<f name="VALUE4" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="ksgzltjnumZyDao" log="true" type="1" memo="科室工作量人次-住院">
<sql><![CDATA[
select count(*) num,jjks,yzxzys from(select distinct a.jjks,a.jjys yzxzys,a.pkey from HIS_JZ_BASEINFO a left join HIS_YZ_MXB b on a.pkey=b.jzpkey and a.JGID=b.JGID left join HIS_SFZD_SFXMXB c on b.pkey=c.yzmx and b.JGID=c.JGID left join HIS_SFX sfx on c.sfx=sfx.bm and c.JGID=sfx.JGID left join MAIN_JGZDB jgzdb on sfx.fyzl=jgzdb.bh and sfx.JGID=jgzdb.JGID and jgzdb.JGZDLB_BH='Z00004' where a.JGID=? and (a.JZLX='Z' or a.JZLX='J' ) and nvl(a.jjks,'%') like ? and a.jjrq >=? and a.jjrq <=? ) group by jjks,YZXZYS order by jjks,YZXZYS
]]></sql>
<fields>
<f name="NUM" type="4" />
<f name="JJKS" type="12" />
<f name="YZXZYS" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
</datasource>