I’m curious to know if anyone has written an sql script to update the database concept tree locally in a database; if there is one can you point me to it - otherwise I will have to write one from scratch.
@ekoseos Are you trying to add more concepts? Or adding concept set members? Or adding reference terms (ie. ICD10, ICD11, RxNORM, LOINC, SNOMED-CT) to concepts? Or all of the above?
At Partners In Health, we use OpenConceptLab (OCL) to manage our concept dictionary. The OCL bulk import is a great tool for adding/modifying concepts using csv files.
- OCL: https://openconceptlab.org/
- OCL documentation (bulk import): Bulk Import API — ocl-docs 2.0 documentation
- Training: OpenMRS Concept Management Using OCL – OpenMRS.org
Feel free to join the weekly OCL squad meeting on Wednesdays or reach out on OpenMRS Slack (ocl).
Best regards and welcome.
FYI @jamlung
Thank you for the information; I had already reviewed the ocl and training pages - we are limited from using the OCL; once more there is a new standard ICD10-CA that we will be implementing as well as missing SNOMED-CT reference terms. The second problem is we are producing a multi-device system (phone, watch, etc) and will need to move a subset of the schema onto small device environments. OCL would be impractical for these environments. Our initial investigation is to see if we can just update the database directly, and then look at developing an api service that generates a database under a small footprint environment. Another aspect is that some emr clients would have no internet connectivity, and would need to run offline - sometimes as a miniturized impelmentation.
Hi @ekoseos - great to meet you! As @ball said, the OpenMRS-OCL Squad call is a great place to talk more about this with the experts. I can add a couple of thoughts here too.
Offline EMRs are one of the use cases that OCL and OpenMRS work well on. Many people export terminology content out of OCL so that it can be imported into OpenMRS, even without a live internet connection. OCL in that case serves as the management platform for the terminology, not necessarily the API that EMRs would query in real time.
If you are worried about missing terminologies like SNOMED-CT, it’s certainly possible to deploy your own instance of OCL that holds the content you need. You would have full control over the content in that case, and you would be charged with managing it in the long term.
SNOMED has also explored the idea of making SNOMED-CT available in OCL too, so it might not hurt to tell SNOMED that you would like to see their content in OCL.
If you had development resources, it’d also be easy to build out the licensing features in OCL too, which wouldn’t even require SNOMED-CT approval to make that content available! Probably the same with ICD-10-CA too!
Generally—at least for OpenMRS—it’s preferable to load concepts via the Java API rather than via a SQL script, as parts of the concept dictionary are also stored in the search index. The OCL module demonstrates an approach to loading data from a source into the concept dictionary using the API.
Thank you very much for the reply, your comments are helpful - I had considered using OCL; however, we can’t cross our country borders in healthcare to use such a tool or any other openmrs connection less we break our legislation and HIPAA compliancy. Running local is an option, however most providers would not be willing to manage it. It might actually be better for us to build our own tool - which is what we are looking at presently and make it available via a local cloud platform for free. The database update via script is just a first step and seems a lot easier to me based on the “particulate” design of the omrs database currently. We are actually working closely with SNOMED to standardize the concepts locally but leaving room for international implementation that would include FHIR and CDA. I’ve re-versed engineered the schema for 2.7 and o3.4 already. Will consider connecting in the squad when I have time. Myself and a few others are already experts on the backend and training one or two people on the frontend. I was basically looking to see if anyone had already done this before manually without OCL.