药品对应

insert into Z_Dict_List (YaoPinID, HiID, ShiYongXZ, ShiYongXZMC, ZiFuBL, ShouFeiLB, ShouFeiLBMC,YaoPinLB, YaoPinLBMC, YaoPinJX, XianZhiLB)
         values ('02-14-0376', '8888888', .050, 2, :ZiFuBL, 2, 乙类, :YaoPinLB, :YaoPinLBMC, :YaoPinJX, :XianZhiLB)

--ShiYongXZ:草药为1 其余为0  ShiYongXZMC:对应为 限制 与不限制 --ShouFeiLB ShouFeiLBMC 1 西药费,2 中成药
---YaoPinLB, YaoPinLBMC  1  '甲类'  2  '乙类'   '自费
----ShiYongXZMC:: XianZhiLB when 0 then '不限制'      when 1 then '限制'

医院目录SQL:

select b.FeiYongNo, a.HiID, a.HiFeiYongMC, a.ShiYongXZ, a.ShiYongXZMC, a.ShouFeiLB, a.ShouFeiLBMC, a.FeiYongLB,
    a.FeiYongLBMC, a.ShenPiJB, a.ShenPiJBMC, a.ZiFuBL, b.FeiYongMC, b.DanWei,
   b.YiYuanSF as DanJia, b.PinYinMa, b.WuBiMa, c.HeSuanMC
   from Z_Dict_Charge a right join Dict_HosCharge b on a.FeiYongNo=b.FeiYongNo
   inner join Dict_CheckItem c on b.HeSuanBM=c.HeSuanBM
   order by a.ShouFeiLB,b.FeiYongNo

 医保目录SQL:

 

View Code

  select a.FeiYongNo, a.ZiFuBL, a.FeiYongMC, a.ShouFeiLB,
 ShouFeiLBMC=b.HeSuanMC, a.FeiYongLB, a.FeiYongLBMC,
   a.BeiZhu,a.PinYinMa,a.WuBiMa
 from Z_Hi_Charge a,Z_Hi_CheckItem b
 where a.ShouFeiLB=b.HeSuanBM
 order by a.ShouFeiLB,a.FeiYongNo

posted on 2009-09-08 23:03  舟山牙医  阅读(188)  评论(0编辑  收藏  举报

导航