Stream: implementers
Topic: FHIR DB Schema
Peter Kasson (Sep 21 2017 at 09:11):
I have been searching high and low, and must be missing it .. but I know I found it last year - a SQL DDL that would create all the FHIR compliant tables in MySQL - any help here would be appreciated !
Jose Costa Teixeira (Sep 21 2017 at 09:14):
Grahame's server runs on a MySQL DB. Is that what you are after?
Peter Kasson (Sep 21 2017 at 09:15):
Grahame's server runs on a MySQL DB
Right, I am looking for the SQL that will generate all the FHIR tables. I have see the FHIR server projects but have never seen any of the SQL that builds the initial tables
Jose Costa Teixeira (Sep 21 2017 at 09:16):
To install the server? The installer does that automatically
Grahame Grieve (Sep 21 2017 at 09:16):
no he
Grahame Grieve (Sep 21 2017 at 09:17):
@Peter Kasson is looking for something else - something that generates detailed table structures for the resources
Peter Kasson (Sep 21 2017 at 09:29):
no he
So during initial run, the server generates the schema ?
Peter Kasson (Sep 21 2017 at 09:30):
@Jose Costa Teixeira So during initial run, the server generates the schema ?
Jose Costa Teixeira (Sep 21 2017 at 09:35):
The server creates and populates the database. If you are looking for a schema from that, what you can always do is run any tool like heidisql to retrieve the schema from the database. but that is a normalized version, not with the different resources.
Jose Costa Teixeira (Sep 21 2017 at 09:35):
if you are looking for tables for each resource type, etc, that i do not know
Peter Kasson (Sep 21 2017 at 09:39):
if you are looking for tables for each resource type, etc, that i do not know
Thanks ... thats what it appeared based on the projects I have seen, but I never saw any raw SQL that you would expect, that was used to create the schema , seems a bit odd. Ok, where can I get an easy to use / install server from ?
Jose Costa Teixeira (Sep 21 2017 at 09:40):
the link above has an installer
Jose Costa Teixeira (Sep 21 2017 at 09:40):
click, click, you are done
Peter Kasson (Sep 21 2017 at 09:42):
click, click, you are done
Don't see the link :(
Jose Costa Teixeira (Sep 21 2017 at 09:42):
oh sorry
http://www.healthintersections.com.au/FhirServer/fhirserver.htm
Peter Kasson (Sep 21 2017 at 09:43):
oh sorry
http://www.healthintersections.com.au/FhirServer/fhirserver.htm
Thanks Jose !
Jose Costa Teixeira (Sep 21 2017 at 09:44):
requirements: MariaDB or MYSQL. If MariaDB, Please use Version below 10.2 if you want to do search (there is a silly bug in mariaDB and the FHIR server patch is not yet out)
Peter Kasson (Sep 21 2017 at 10:14):
requirements: MariaDB or MYSQL. If MariaDB, Please use Version below 10.2 if you want to do search (there is a silly bug in mariaDB and the FHIR server patch is not yet out)
Thanks again !
Peter Kasson (Sep 21 2017 at 10:23):
requirements: MariaDB or MYSQL. If MariaDB, Please use Version below 10.2 if you want to do search (there is a silly bug in mariaDB and the FHIR server patch is not yet out)
Is there a trick to installing on SQL Server (the installer defaults to this). I put in all the SQL Server details, but when creating the database, it fails with:
Initializing the database failed - can't connect to: \\SQL Server\ipaddress\FHIR ..
It should not be putting that \\SQL Server" in the url
Jose Costa Teixeira (Sep 21 2017 at 10:25):
did you install the odbc connectors for SQL Server?
Peter Kasson (Sep 21 2017 at 10:26):
did you install the odbc connectors for SQL Server?
No ... been a while since using ODBC and Windows ... trying that now
Arvind Martin (May 25 2018 at 06:32):
I want to create tables in MySQl to support the FHIR Resources. Does anybody have the DDL for creating tables for the FHIR resources in MySQL?
I would like to have a table for each resource i.e Patient, Observation etc
I am looking for a DB script that would create tables for each of the resources with the internal relationships. Please help!
Grahame Grieve (May 25 2018 at 06:53):
there is no standard DDL like this because everyone makes different decisions about how they want their tables laid out. Most of the resources have 3-4 levels of nested structure, though there may be more (and some are recursive). You have to decide this for yourself
Muhammad Abubakar Ikram (May 25 2018 at 10:44):
If you don't have any specific requirement to use MySql, then go for schema-less DBs like MongoDB you'll be in no pain.
Vadim Peretokin (May 25 2018 at 10:50):
JSON support in PostgreSQL works just as well (and I'm sure it would in SQL Server)
Kevin Olbrich (May 25 2018 at 11:19):
For some use cases it makes sense to represent objects using your internal domain modeling and store them in tables that make sense for your business use case and then serialize to/from FHIR as needed. That way your DB structure is in no way tied to the FHIR standard and you can manage it as you see fit.
Arvind Martin (Jun 01 2018 at 05:15):
Thank you, Grahame.
Last updated: Apr 12 2022 at 19:14 UTC