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.
<MedicationDispense xmlns="http://hl7.org/fhir"> <id value="core-examples-MedicationDispense-example5" /> <meta> <versionId value="1" /> <lastUpdated value="2016-09-08T11:58:23.329+00:00" /> </meta> <text> <status value="generated" /> --- We have skipped the narrative for better readability of the resource --- </text> <status value="completed" /> <patient> <reference value="Patient/example" /> </patient> <dispenser> <reference value="Practitioner/example" /> </dispenser> <authorizingPrescription> <reference value="MedicationOrder/medrx002" /> </authorizingPrescription> <type> <coding> <system value="http:hl7.org/fhir" /> <code value="FF" /> <display value="First Fill" /> </coding> </type> <quantity> <value value="100" /> <unit value="mL" /> <system value="http://unitsofmeasure.org/" /> <code value="mL" /> </quantity> <daysSupply> <value value="10" /> <unit value="Day" /> <system value="http://unitsofmeasure.org/" /> <code value="D" /> </daysSupply> <medicationReference> <reference value="Medication/medexample003" /> <display value="prescribed medication" /> </medicationReference> <whenPrepared value="2015-01-15T16:20:00Z" /> <whenHandedOver value="2015-01-16T10:20:00Z" /> <dosageInstruction> <additionalInstructions> <coding> <system value="http://snomed.info/sct" /> <code value="311504000" /> <display value="With or after food" /> </coding> </additionalInstructions> <timing> <repeat> <frequency value="3" /> <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="5" /> <unit value="mL" /> <system value="http://unitsofmeasure.org/" /> <code value="mL" /> </doseQuantity> </dosageInstruction> </MedicationDispense>