SQL on FHIR
2.1.0-pre - release
SQL on FHIR - Local Development build (v2.1.0-pre) built by the FHIR (HL7® FHIR® Standard) Build Tools. See the Directory of published versions
draft |
Generated Narrative: ViewDefinition UsCoreBloodPressures
This view acts on the Observation resource to produce a table named "us_core_blood_pressures
" where code.coding.exists(system='http://loinc.org' and code=%bp_code)
.
The table contains the following columns:
Name | Fhir Type | SQL Type | Collection |
---|---|---|---|
id | string | String | |
patient_id | string | String | |
effective_date_time | dateTime | DateTime | |
sbp_quantity_system | uri | String | |
sbp_quantity_code | string | String | |
sbp_quantity_unit | string | String | |
sbp_quantity_value | decimal | Decimal | |
dbp_quantity_system | uri | String | |
dbp_quantity_code | string | String | |
dbp_quantity_unit | string | String | |
dbp_quantity_value | decimal | Decimal |
Constants:
Name | Value |
---|---|
systolic_bp | 8480-6 |
diastolic_bp | 8462-4 |
bp_code | 85354-9 |
Selection Rules:
Item | Coll | Type | Description |
---|---|---|---|
us_core_blood_pressures | Observation | ||
Select | |||
id | getResourceKey() | ||
patient_id | subject.getReferenceKey(Patient) Can be used to join to patient tables created by other views. | ||
effective_date_time | effective.ofType(dateTime) | ||
Select | for each component.where(code.coding.exists(system='http://loinc.org' and code=%systolic_bp)).first() | ||
sbp_quantity_system | value.ofType(Quantity).system | ||
sbp_quantity_code | value.ofType(Quantity).code | ||
sbp_quantity_unit | value.ofType(Quantity).unit | ||
sbp_quantity_value | value.ofType(Quantity).value | ||
Select | for each component.where(code.coding.exists(system='http://loinc.org' and code=%diastolic_bp)).first() | ||
dbp_quantity_system | value.ofType(Quantity).system | ||
dbp_quantity_code | value.ofType(Quantity).code | ||
dbp_quantity_unit | value.ofType(Quantity).unit | ||
dbp_quantity_value | value.ofType(Quantity).value |