
SQL-on-FHIR, built in.
Run ViewDefinitions against live data and export to CSV, JSON, NDJSON, or Parquet. Python bindings included.
View Definitions
Author and manage the ViewDefinitions that SQL on FHIR runs flatten resources with.
VIEW DEFINITIONS⌕ Filter viewsRECENTLY USED
- patient_addressesPatient
- us_core_blood_pressuresObservation
- shareable_patient_demographicsPatient
- questionnaire_response_itemsQuestionnaireResponse
- patient_names_with_indexPatient
- code_system_hierarchyCodeSystem
- condition_flatCondition
- encounter_flatEncounter
- patient_addressesPatient
- patient_and_contact_addressesPatient
- patient_demographicsPatient
- patient_names_with_indexPatient
- questionnaire_response_itemsQuestionnaireResponse
- shareable_patient_demographicsPatient
- us_core_blood_pressuresObservation
▦ patient_addresses⧉ Duplicate🗑 Delete+ Create New
Definition (JSON)● Runs as you type — results follow the current definitionFormat
1{
2"resourceType": "ViewDefinition",
3"resourceDefinition":
4"http://hl7.org/fhir/uv/sql-on-fhir/StructureDefinition/ViewDefinition",
5"select": [
6{
7"column": [
8{ "path": "getResourceKey()", "name": "patient_id" }
9]
10},
11{
12"forEach": "address",
13"column": [
14{
15"path": "line.join('\n')",
16"name": "street",
17"description": "The full street address."
18},
19{ "path": "use", "name": "use" },
20{ "path": "city", "name": "city" },
21{ "path": "postalCode", "name": "zip" }
22]
23}
24]
25}
CancelSave
⚙ Guided formNo issues.
● Checked as you type: structure, cardinality, required bindings and FHIRPath syntax
ViewDefinition ViewDefinition
id
id01a15a1e-93ad-7b13-8ada-a353a1b21574Logical id of this artifactversionId
id1Version specific identifierlastUpdated
instant2026-10-20T16:21:55.758ZWhen the resource version last changedlanguage
codeenLanguage of the resource contentstatus
codegeneratedgenerated | extensions | additional | emptyname
stringpatient_addressesName for this view definition (computer friendly)status
codedraftdraft | active | retired | unknownresource
codePatientFHIR resource for the ViewDefinitionResults50 rows · 11 ms
PATIENT_IDSTREETUSECITYZIP
7d24f7a0-6f2e-ce3b-5568-db7b14695583492 Conn ClubhomeEverett02149
44219cdc-80b3-18be-fd67-fbb019971384194 Willms MewshomeArlington02476
44a2f44f-1f46-43ee-8c1f-fd86d4081520386 Watsica Loaf Unit 10homeWestwood02090
06c5e8e3-0e46-d195-bf30-7a5396894b57895 Mosciski CamphomeTyngsboro01879
24531131-f9df-5f7f-7e6f-5630151caeed290 Leffler ForkhomeWaltham02472
627deb5a-b17b-5c08-3bae-bf384381adac107 Mueller CrossroadhomeBoston02210
8a18f5ac-c2e7-6318-a76c-d5ae4f54c13b206 Dare Trailer Unit 8homeCanton02021
73980a37-c279-25bc-7506-fc58b97984fe164 Monahan ValehomeMethuen01841
65c3af91-faec-8df4-7b6d-29f9b6cf3d1e1067 Kiehn Port Suite 12homeCanton02021
c0832d57-9cc4-7178-d8d8-7437f1c312f01032 McKenzie TrafficwayhomeNeedham02494
3b9eadad-d44c-568c-88b4-89cd73a6a33f236 Block Club Unit 44homeTaunton02718
fcc6a489-3d58-c9cc-cc1e-512ef74f5911767 Toy CrossroadworkHull02045
4a76fd03-96e7-9482-4167-be6006ea79b5535 Rippin Underpass Unit 36homeNatick01760
3a04a0d9-a4df-a097-205b-f59044ec1844261 Sauer CrossinghomeEverett02149
f49dd24f-6e78-eb3b-eb47-cd5955babb2d223 Moen Wynd Apt 1homeWorcester01602
aaea74e0-f712-9256-0c69-1618624ef029834 Littel JunctionhomeFall River02721
SQL Exports
0 exports · 0 running
No SQL exports yet. Use New SQL Export to start one.
patient_addressesIn progressCancel⋮
Writing patient_addresses · 0 of 1 subject (1 ViewDefinition) · NDJSON · started 20:37 UTC
‹ SQL Exports
New SQL Export
Run stored view definitions, SQL queries and SQL views as a long-running $sql-export job and download the output files.
NameMonthly patient flat filesWhat are you exporting?
⛁ Subjects10All▦ View Definitions<> Queries⛁ ViewsFilter subjects
SUBJECTKINDSTATUS
code_system_hierarchyViewDefinitiondraft
condition_flatViewDefinitiondraft
encounter_flatViewDefinitiondraft
patient_addressesViewDefinitiondraft
patient_and_contact_addressesViewDefinitiondraft
patient_demographicsViewDefinitiondraft
patient_names_with_indexViewDefinitiondraft
questionnaire_response_itemsViewDefinitiondraft
shareable_patient_demographicsViewDefinitiondraft
us_core_blood_pressuresViewDefinitiondraft
0 of 10 selected
⇋ Narrow it downoptional — leave empty to export everything
PATIENTS⌕ Search patients
GROUPS⌕ Search groups
SINCEAll time ⌄
CUSTOM INSTANT2026-08-01T00:00:00Z
Output format
NDJSONOne JSON object per row. Streams well into pipelines.
CSVHeader row plus one line per row. Opens in any spreadsheet.
JSONA single JSON array per output. Easiest to inspect by hand.
ParquetColumnar and typed. Best for analytics engines.
› Advanced
⇪ Start Export