BMS-HOSxP Community

HOSxP => Report Exchange => ข้อความที่เริ่มโดย: jaynak ที่ มีนาคม 03, 2010, 10:21:18 AM

หัวข้อ: เขียน variable แล้วค่าไม่ออกครับ
เริ่มหัวข้อโดย: jaynak ที่ มีนาคม 03, 2010, 10:21:18 AM
Value := GetSQLStringData ( 'select count(distinct o.hn) as total from ovst o'+
          'left outer join patient p on p.hn=o.hn'+
          'left outer join clinicmember c on c.hn=o.hn'+
          'where o.vstdate between "2009-10-01" and "2009-10-31"'+
          'and c.clinic = "001"'+
          'and p.chwpart = "36"'+
          'and p.amppart = "10"'+
          'and p.tmbpart = "01"');


ค่ามันไม่ออกอะครับ
เอาไปใส่ใน SQL Query ค่าก็ออกนะครับ ช่วยชี้แนะทีครับ
หัวข้อ: Re: เขียน variable แล้วค่าไม่ออกครับ
เริ่มหัวข้อโดย: pop_hosxp ที่ มีนาคม 03, 2010, 10:25:47 AM
เพิ่มช่องว่างอีกนิดครับ

Value := GetSQLStringData ( 'select count(distinct o.hn) as total from ovst o '+
          ' left outer join patient p on p.hn=o.hn '+
          ' left outer join clinicmember c on c.hn=o.hn '+
          ' where o.vstdate between "2009-10-01" and "2009-10-31" '+
          ' and c.clinic = "001" '+
          ' and p.chwpart = "36" '+
          ' and p.amppart = "10" '+
          ' and p.tmbpart = "01" ');
หัวข้อ: Re: เขียน variable แล้วค่าไม่ออกครับ
เริ่มหัวข้อโดย: jaynak ที่ มีนาคม 03, 2010, 10:51:30 AM
ขอบคุณครับ ได้แล้วครับ