Your User Friendly Name for MyContentIG Here
0.4.6 - CI Build International flag

Your User Friendly Name for MyContentIG Here, published by HL7 International - [Some] Work Group. This guide is not an authorized publication; it is the continuous build for version 0.4.6 built by the FHIR (HL7® FHIR® Standard) CI Build. This version is based on the current content of https://github.com/cqframework/sample-content-ig/ and changes regularly. See the Directory of published versions

Library: Retrieve Example (Experimental)

Official URL: http://somewhere.org/fhir/uv/mycontentig/Library/RetrieveExample Version: 0.4.6
Draft as of 2024-09-19 Computable Name: RetrieveExample

Example library illustrating CQL retrieve with terminology

Title: Retrieve Example
Id: RetrieveExample
Version: 0.4.6
Url: Retrieve Example
Status: draft
Experimental: true
Type:

system: http://terminology.hl7.org/CodeSystem/library-type

code: logic-library

Subject:

system: http://hl7.org/fhir/resource-types

code: Patient

Date: 2024-09-19 19:22:59+0000
Publisher: HL7 International - [Some] Work Group
Description:

Example library illustrating CQL retrieve with terminology

Jurisdiction: 001
Related Artifacts:

Dependencies

Parameters:
NameTypeMinMaxIn/Out
PatientPatient01Out
Smoking status observationObservation0*Out
Lung cancer diagnosisCondition0*Out
Data Requirements:
TypeProfileMSCode Filter
Patient http://hl7.org/fhir/StructureDefinition/Patient
Observation http://hl7.org/fhir/StructureDefinition/Observation ;; code filter:
path: code

system: http://loinc.org

code: 72166-2

Condition http://hl7.org/fhir/StructureDefinition/Condition ;; code filter:
path: code
value set: http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1116.89
Content: text/cql
library RetrieveExample version '0.4.1'

using FHIR version '4.0.1'

include FHIRHelpers version '4.0.1'

codesystem "LOINC": 'http://loinc.org'

valueset "Lung Cancer":  'http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1116.89'
valueset "Condition Clinical Status": 'http://utah.edu/fhir/lcs-cds/ValueSet/conditionclinical'

code "Tobacco Smoking Status": '72166-2' from "LOINC"

context Patient

define "Smoking status observation":
  [Observation: "Tobacco Smoking Status"] O
    where O.status in { 'final', 'amended' }

define "Lung cancer diagnosis":
  [Condition: "Lung Cancer"] C
    where C.clinicalStatus in "Condition Clinical Status"
Content: application/elm+xml
Encoded data (14460 characters)
Content: application/elm+json
Encoded data (25228 characters)