Advertisement
aloumaf

openmrs sql dataset

Dec 6th, 2020 (edited)
34
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. select pa.value as Direction, round((count(*)*100/totalagent)) as Pourcentage
  2. from visit v, person_attribute pa, (select count(*) as totalagent from patient where
  3. voided!= "1") as c
  4. where v.voided != "1"
  5. and v.date_started >= :startDate
  6. and v.date_started <= :endDate
  7. and pa.person_attribute_type_id = "13"
  8. and v.patient_id = pa.person_id
  9. and pa.voided != "1"
  10.  
  11. group by Direction
Advertisement
RAW Paste Data Copied
Advertisement