FQL is a query language that allows you to retrieve, filter and project data from any data source containing FHIR Resources. It brings the power of three existing languages together: SQL, JSON and FhirPath. It allows you to create tables and is useful for gaining insight and perform quality control.
<MedicationOrder xmlns="http://hl7.org/fhir"> <id value="core-examples-MedicationOrder-example18" /> <meta> <versionId value="1" /> <lastUpdated value="2016-09-08T11:58:24.926+00:00" /> </meta> <text> <status value="generated" /> --- We have skipped the narrative for better readability of the resource --- </text> <identifier> <use value="official" /> <system value="http://www.bmc.nl/portal/prescriptions" /> <value value="12345" /> </identifier> <dateWritten value="2015-01-15" /> <status value="active" /> <patient> <reference value="Patient/f001" /> <display value="Eve Everywoman" /> </patient> <prescriber> <reference value="Practitioner/f007" /> <display value="Patrick Pump" /> </prescriber> <encounter> <reference value="Encounter/f002" /> <display value="encounter who leads to this priscription" /> </encounter> <reasonCodeableConcept> <coding> <system value="http://snomed.info/sct" /> <code value="195967001" /> <display value="Asthma" /> </coding> </reasonCodeableConcept> <medicationReference> <reference value="Medication/MedicationExample11" /> <display value="prescribed medication" /> </medicationReference> <dosageInstruction> <text value="Take 1 tablet twice daily for 3 days" /> <additionalInstructions> <coding> <system value="http://snomed.info/sct" /> <code value="311504000" /> <display value="With or after food" /> </coding> </additionalInstructions> <timing> <event value="2015-03-01" /> <repeat> <duration value="3" /> <durationUnits value="d" /> <frequency value="2" /> <period value="1" /> <periodUnits value="d" /> </repeat> </timing> <siteCodeableConcept> <coding> <system value="http://snomed.info/sct" /> <code value="181220002" /> <display value="Entire oral cavity" /> </coding> </siteCodeableConcept> <route> <coding> <system value="http://snomed.info/sct" /> <code value="26643006" /> <display value="Oral Route" /> </coding> </route> <doseQuantity> <value value="1" /> <system value="http://hl7.org/fhir/v3/orderableDrugForm" /> <code value="TAB" /> </doseQuantity> </dosageInstruction> <dosageInstruction> <text value="Take 2 tablet twice daily for 3 days" /> <additionalInstructions> <coding> <system value="http://snomed.info/sct" /> <code value="311504000" /> <display value="With or after food" /> </coding> </additionalInstructions> <timing> <event value="2015-03-04" /> <repeat> <duration value="3" /> <durationUnits value="d" /> <frequency value="2" /> <period value="1" /> <periodUnits value="d" /> </repeat> </timing> <siteCodeableConcept> <coding> <system value="http://snomed.info/sct" /> <code value="181220002" /> <display value="Entire oral cavity" /> </coding> </siteCodeableConcept> <route> <coding> <system value="http://snomed.info/sct" /> <code value="26643006" /> <display value="Oral Route" /> </coding> </route> <doseQuantity> <value value="2" /> <system value="http://hl7.org/fhir/v3/orderableDrugForm" /> <code value="TAB" /> </doseQuantity> </dosageInstruction> <dosageInstruction> <text value="Take 3 tablet twice daily for 3 days" /> <additionalInstructions> <coding> <system value="http://snomed.info/sct" /> <code value="311504000" /> <display value="With or after food" /> </coding> </additionalInstructions> <timing> <event value="2015-03-07" /> <repeat> <duration value="3" /> <durationUnits value="d" /> <frequency value="2" /> <period value="1" /> <periodUnits value="d" /> </repeat> </timing> <siteCodeableConcept> <coding> <system value="http://snomed.info/sct" /> <code value="181220002" /> <display value="Entire oral cavity" /> </coding> </siteCodeableConcept> <route> <coding> <system value="http://snomed.info/sct" /> <code value="26643006" /> <display value="Oral Route" /> </coding> </route> <doseQuantity> <value value="3" /> <system value="http://hl7.org/fhir/v3/orderableDrugForm" /> <code value="TAB" /> </doseQuantity> </dosageInstruction> </MedicationOrder>