jeniferfleurant icon

# Enfants PCR positifs, mort, sur ARV

jeniferfleurant | PRO | 09/02/16 04:50:02 PM UTC | 0 ⭐ | 408 👁️ | Never ⏰ | []
MySQL |

740 B

|

None

|

0 👍

/

0 👎

select count(*) from ( 
select * from (select id_patient as id from tracking_infant where  eid_pcr_program=1 and (positive_pcr_1!='0000-00-00' or positive_pcr_2!='0000-00-00' 
or comments like '%Added via bulk upload%'
)
) a 
union  
select id_patient as id from testing_specimen where pcr_result=1
union  select id_patient as id from testing_result where result=1
  ) r
where id not in (select id from patient where linked_to_id_patient!=0)
#patient positive dead
and id in (select id_patient from tracking_infant where is_dead=1)
#on arv 
and id  in (select id_patient from tracking_regime where id_arv!=0
 UNION select * from (select id_patient from tracking_followup where on_arv=1) f)
 and id in (select id_patient from tracking_infant)

Comments