BMS-HOSxP Community
HOSxP => แจ้งปัญหา / ขอความช่วยเหลือ => ข้อความที่เริ่มโดย: nu51313932nu ที่ กุมภาพันธ์ 23, 2017, 16:49:15 PM
-
ช่วยหน่อยนะครับ ผมลองหมดแล้ว มันไม่ได้สักอันเลย
โดยที่ผมแก้มีดังนี้ครับ เป็นการเพิ่มสามบรรทัดตามภาพตัวอย่าง โดยไม่ได้แก้ใน SQL เริ่มต้น แต่ใช้ Variable ดึงมาครับ
จาก Report Designer
1.FORM-Sticker-OPD-Detail
select d1.*,v1.*,o1.*
from doctor_order_print d1
left outer join vn_stat v1 on v1.vn=d1.vn
left outer join ovst o1 on o1.vn=d1.vn
where d1.vn="600223134457" and d1.print_server="OPD" and d1.icode like "1%"
group by d1.icode
แล้วใช้ Variable ดึงข้อมูลเหมือนกับโค้ดสามแถวด้านล่างครับ
ผลที่ได้ จากการพรีวิว
(https://www.mx7.com/i/1fd/WvWtgc.png)
2.แก้ไขใน Print Server Hosxp
โดยการ ใช้ SQL variable ดึงข้อมูลมาเพิ่ม ดังนี้
Value := GetSQLStringData('select therapeutic from drugitems where icode =" ' +DBPipeline1['icode']+' " ');
Value := GetSQLStringData('select hintcode_eng from drugitems where icode =" ' +DBPipeline1['icode']+' " ');
Value := GetSQLStringData('select therapeutic_eng from drugitems where icode =" ' +DBPipeline1['icode']+' " ');
มองไม่เห็นตัวอย่างแบบเต็ม เพราะ เราใส่ Parameter ไม่ได้ใน Print Server
ซึ่งผมลองปริ้นแล้ว มันไม่ขึ้นตามที่ออกแบบอ่ะครับ มันจะขึ้นเหมือนแบบเก่า เลยสงสัยว่า แก้ผิดฟอร์มมันหรือเปล่า
-
ใช้ print server ตัวไหนครับ ;D
ถ้าใช้ตัวในรูปต้อง ติ๊กถูก ที่ใช้ออกแบบเองครับ