Migrate data from other system to bahmni

Hellow team, Am new to bahmni, I have another system installed in a hospital, I would like to use bahmni instead, the system has the record concern the visit. I tried to run SQL queries that will insert data to the following tables

  1. person
  2. patient
  3. person_name
  4. patient_identifier
  5. visit

After that, I couldn’t able to see patient on the search, Please what did I miss? Help.

Hello @johnbosco91,

For importing the following details into the Bahmni , You can use Bahmni’s Patient data migration functionaity:

  • person
  • patient
  • person_name
  • patient_identifier
  • visit

How to create csv file:

How to import csv into Bahmni. (Reference link)

  • Import the csv file
    • Login to Bahmni EMR with admin access (i.e. user : superman)
    • Select “Admin module” from the home dashboard.
    • Select “CSV Upload”
    • Select the type of data (Concept, Encounter, Drug, etc.) you want to upload and choose the file which has the data

Note: Don’t insert the patient data into database through sql queries.

Hope this will help you…!!

Hello @amolsatvix, Thank you for the reply. Your suggestions helps out.

1 Like

Would someone explain how coded data could be migrated without synchronizing to the concept dictionary? It wasn’t clear to me from the Bahmni wiki page referenced how that happens… it looks like it is just a text field for diagnosis, for example.

It seems Bahmni provides way to import different parts of the medical record captured in other system

The documentation only specifies the formats for patient, encounters and lab results. How to figure out the formats for other parts like drugs?

Also, ideally it would be good to have the formats available in this screen only rather than having to go to documentation.

1 Like

Hi Arjun

I see some sample CSVs checked in here:

Maybe these are the formats? Can someone validate or share their own implementation’s example of data import csv into Bahmni?

I found some more on github using this search: Search github for bahmni-config

Mentioned them here on Confluence as a comment: https://bahmni.atlassian.net/wiki/spaces/BAH/pages/18415806/Configure+CSV+Import

2 Likes

The samples for Drug looks right.

In code, for Drug you can see the fields here: https://github.com/Bahmni/bahmni-core/blob/ccbe25e24ad33f1f07cf0871391decb2f98498c0/admin/src/main/java/org/bahmni/module/admin/csv/models/DrugRow.java#L10-L9

All persisters for different types can be seen here (and from there the individual fields)

https://github.com/Bahmni/bahmni-core/tree/c6ed4f224c52f13186804d45f9d8b4ba148e2f03/admin/src/main/java/org/bahmni/module/admin/csv/persister

But I agree - a link to samples should be easy to find for imports so people don’t need to go hunting.

1 Like

Thanks Gurpreet. it would be good to add the drug sample here as other formats are there on this page : Bahmni Documentation Wiki

And on the import screen itself. There should be an option saying “Download sample formats” which can download a zip file containing sample file for each data type and with some sample rows.

1 Like