BMS-HOSxP Community

HOSxP => แจ้งปัญหา / ขอความช่วยเหลือ => ข้อความที่เริ่มโดย: bangpahan ที่ ตุลาคม 26, 2007, 14:27:48 PM

หัวข้อ: ฝากอาจารย์อ๊อดช่วยด้วยครับ
เริ่มหัวข้อโดย: bangpahan ที่ ตุลาคม 26, 2007, 14:27:48 PM
select op.*,
concat(p.pname,p.fname,'  ',p.lname) as tname,d.name
from opitemrece op,patient p
left outer join drugitems d on d.icode = op.icode
where rxdate between '2006-12-01' and '2006-12-15'
and op.icode like '1460176'
and op.hn = p.hn
หัวข้อ: Re: ฝากอาจารย์อ๊อดช่วยด้วยครับ
เริ่มหัวข้อโดย: SrWooD ที่ ตุลาคม 26, 2007, 14:40:26 PM
น่าจะเป็นแบบนี้นะครับ

select op.*,
concat(p.pname,p.fname,'  ',p.lname) as tname,d.name
from opitemrece op
left outer join patient p on op.hn=p.hn
left outer join drugitems d on d.icode = op.icode
where rxdate between '2006-12-01' and '2006-12-15'
and op.icode like '1460176'
and op.hn = p.hn

หัวข้อ: Re: ฝากอาจารย์อ๊อดช่วยด้วยครับ
เริ่มหัวข้อโดย: bangpahan ที่ ตุลาคม 26, 2007, 14:59:49 PM
ได้แล้วครับ
ขอบคุณครับพี่วุฒิ
หัวข้อ: Re: ฝากอาจารย์อ๊อดช่วยด้วยครับ
เริ่มหัวข้อโดย: doramon ที่ ตุลาคม 26, 2007, 15:20:59 PM
ขอบคุณมาก
เข้าเวปไม่ได้สองวันแล้ว