SQL on FHIR
2.1.0-pre - release
SQL on FHIR, published by SQL on FHIR Working Group. This guide is not an authorized publication; it is the continuous build for version 2.1.0-pre built by the FHIR (HL7® FHIR® Standard) CI Build. This version is based on the current content of https://github.com/FHIR/sql-on-fhir-v2/ and changes regularly. See the Directory of published versions
{
"resourceType" : "https://sql-on-fhir.org/ig/StructureDefinition/ViewDefinition",
"id" : "PatientAddresses",
"name" : "patient_addresses",
"status" : "draft",
"resource" : "Patient",
"select" : [
{
"column" : [
{
"path" : "getResourceKey()",
"name" : "patient_id"
}
]
},
{
"column" : [
{
"path" : "line.join('\n')",
"name" : "street",
"description" : "The full street address, including newlines if present."
},
{
"path" : "use",
"name" : "use"
},
{
"path" : "city",
"name" : "city"
},
{
"path" : "postalCode",
"name" : "zip"
}
],
"forEach" : "address"
}
]
}
This will result in a “patient_addresses” table that looks like this:
Error processing SQL: [SQLITE_ERROR] SQL error or missing database (no such table: patient_addresses)