Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Moh 706 report #2057

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open

Moh 706 report #2057

wants to merge 2 commits into from

Conversation

Injiri
Copy link
Collaborator

@Injiri Injiri commented Nov 16, 2024

This PR updates additional indicators on the MOH-706 report mapping indicator results for:

  1. Urine Analysis
  2. Blood Chemistry
  3. Parasitology
    MOH 706_Sep-2024.xls

*
* @return @{@link org.openmrs.module.reporting.indicator.dimension.CohortDimension}
*/
public static CohortDefinitionDimension getAge() {

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think there should be this util method already. @patryllus kindly confirm.

sql.addParameter(new Parameter("endDate", "E nd Date", Date.class));
sql.setQuery("SELECT d.patient_id FROM kenyaemr_etl.etl_patient_demographics d\n" +
" INNER JOIN kenyaemr_etl.etl_laboratory_extract x ON x.patient_id = d.patient_id\n" +
" WHERE x.lab_test = 1305 AND x.test_result = 1302 AND date(x.visit_date) BETWEEN :startDate AND :endDate\n" +

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The concept ID 856 and 1305 are for viral load. Please substitute with the correct ones for urinalysis

sql.setName("Get patients with rapid malaria tests");
sql.addParameter(new Parameter("startDate", "Start Date", Date.class));
sql.addParameter(new Parameter("endDate", "End Date", Date.class));
sql.setQuery("SELECT p.patient_id FROM patient p INNER JOIN encounter e ON p.patient_id = e.patient_id INNER JOIN obs o ON e.encounter_id = o.encounter_id "

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We don't want to go this direction. Let's consider introducing ETLs to lessen the load.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants