Uploaded image for project: 'BONNIE MAT MADiE Issue Tracker'
  1. BONNIE MAT MADiE Issue Tracker
  2. BONNIEMAT-1441

CQL Execution Requiring Dosage Instruction to be Present for MedicationRequest

XMLWordPrintable

    • Icon: Bug/Issue Bug/Issue
    • Resolution: Referred to External Party for Resolution
    • Icon: Major Major
    • Measure Calculation
    • None
    • MADiE
    • QI Core
    • Heart Failure (HF): Angiotensin-Converting Enzyme (ACE) Inhibitor or Angiotensin Receptor Blocker (ARB) or Angiotensin Receptor-Neprilysin Inhibitor (ARNI) Therapy for Left Ventricular Systolic Dysfunction (LVSD)FHIR
    • 638d64a04ba3d47c885c030f
    • QI Core/CQL
    • ACEARBOrderedDuringEnc (Group: NUMERPass), ACEARBActAfterEnc (Group: NUMERFail)
    • This impacts the PY 2024 QI-Core conversion of CMS 135.
    • Show
      https://github.com/projecttacoma/fqm-execution/issues/227
    • MADiE 1.1.6
    • Yes

      The following error is received for the test two cases that are mentioned in this ticket:

      The following error occurred in the cql-execution engine: e is not iterable - Inspect the content of the ELM and ensure the data types in the expressions are correct

      This appears to evolve around the "Is Currently Taking ACEI or ARB or ARNI" definition, which sets criteria around dosageInstruction data.

       

      define "Is Currently Taking ACEI or ARB or ARNI":
        exists (
                [MedicationRequest] ActiveACEIOrARBOrARNI
                  let ACE_ARB_ARNI_Reference_Ids: [Medication: "ACE Inhibitor or ARB or ARNI"] ACEIOrARBOrARNI return ACEIOrARBOrARNI.id 
      /*,             DrugPeriod: if ActiveACEIOrARBOrARNI.dosageInstruction is null then null as Interval<DateTime> else
                         First( ( collapse (
                             ActiveACEIOrARBOrARNI.dosageInstruction doseInstruction
                             return doseInstruction.timing.repeat.bounds.toInterval()) 
                                ) DrugPeriods sort by start of $this )
                  with AHA."Heart Failure Outpatient Encounter with History of Moderate or Severe LVSD" ModerateOrSevereLVSDHFOutpatientEncounter 
                    such that DrugPeriod overlaps after day of ModerateOrSevereLVSDHFOutpatientEncounter.period*/
                  where (
                          ( ActiveACEIOrARBOrARNI.medication as Concept ) in "ACE Inhibitor or ARB or ARNI"
                           or ( ActiveACEIOrARBOrARNI.medication as Reference ).reference.getId() in ACE_ARB_ARNI_Reference_Ids
                           )
               and ActiveACEIOrARBOrARNI.overlapsAfterHeartFailureOutpatientEncounter()
               and ActiveACEIOrARBOrARNI.status in { 'active', 'completed' } 
               and ActiveACEIOrARBOrARNI.intent in { 'order', 'original-order', 'reflex-order', 'filler-order', 'instance-order' }
               and ActiveACEIOrARBOrARNI.doNotPerform is not true
                  ) 

       

       

      This is part of the Numerator logic. These two test cases do not include dosageInstruction data for a MedicationRequest resource (profile: http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-medicationrequest), since one was designed to test another portion of the Numerator and the other was to test the Numerator failing. When adding logic to handle the null dosageInstruction (the part in comments) and commenting out the line below, the cases align with the expected results.

      and ActiveACEIOrARBOrARNI.overlapsAfterHeartFailureOutpatientEncounter() 

            Heather.Frideres Heather Frideres
            SRankins Stan Rankins
            Votes:
            0 Vote for this issue
            Watchers:
            7 Start watching this issue

              Created:
              Updated:
              Resolved: