BMS-HOSxP Community
HOSxP => แจ้งปัญหา / ขอความช่วยเหลือ => ข้อความที่เริ่มโดย: sahavej_pct ที่ มีนาคม 13, 2016, 08:48:15 AM
-
ช่วยผมเพิ่ม ชื่อกลุ่มยาหน่อยครับ ตาราง pharmacology_group....ขอบคุณครับ
select concat(b.name,' ',strength) as drugname,generic_name,unitcost,sum(qty),units,b.unitprice ,sum(qty*b.unitprice) as total,f.cur_dep,department
from opitemrece a
left outer join drugitems b on a.icode=b.icode
left outer join ovst f on f.vn = a.vn
left outer join kskdepartment c on f.cur_dep=c.depcode
where a.icode like'1%'
and qty>=1
and f.vstdate between '2016-03-12' and '2016-03-12'
group by b.name,strength,units,b.unitprice,a.dep_code,department
order by f.cur_dep,b.name
-
select concat(b.name,' ',strength) as drugname,generic_name,g.pharmacology_group_name,unitcost,sum(qty),units,
b.unitprice ,sum(qty*b.unitprice) as total,f.cur_dep,department
from opitemrece a
left outer join drugitems b on a.icode=b.icode
left outer join ovst f on f.vn = a.vn
left outer join kskdepartment c on f.cur_dep=c.depcode
left outer join pharmacology_group g on g.pharmacology_group_id=b.pharmacology_group1
where a.icode like'1%'
and qty>=1
and f.vstdate between '2016-03-12' and '2016-03-12'
group by b.name,strength,units,b.unitprice,a.dep_code,department
order by f.cur_dep,b.name
-
กลุ่มยายังไม่มีข้อมูลออกมาครับ
-
ขอดูหน้าจอทะเบียนเวชภัณฑ์ยาที่บันทึกกลุ่มยาครับ
-
ได้แล้วครับ ขอบคุณมากๆๆๆเลยครับ