How to populate the Atlas server database

Tags: #<Tag:0x00007fe6e7a95008> #<Tag:0x00007fe6e7a94e00> #<Tag:0x00007fe6e7a94cc0>

I have installed the server locally, but I don’t have the database populated due to which I am facing constant errors, I have tried a bit to populate them manually with some dummy values which worked a bit but not as expected.

So, what should I do to get the data inserted into my database ? :slight_smile:

Regards
Shekhar

Here’s some sample data from the atlas table (substituting fake uuids):

id,latitude,longitude,name,url,type,image,patients,encounters,observations,contact,email,notes,data,atlas_version,date_created,date_changed,created_by,show_counts,openmrs_version
04959f5e-da0f-4e5f-b5bd-2cd63db98052,39.77864,-86.17785,Regenstrief Institute,http://www.regenstrief.org/,Research,,0,0,0,Burke Mamlin,,,,2012-11-11 20:45:05,2012-11-11 20:45:05,2014-05-23 13:48:33,shekhar,1,
6fd88911-93c7-4c75-af62-c3ec8044ea58,-4.9167,32.8333,Millennium Villages Project,http://www.millenniumvillages.org/,Clinical,,0,0,0,Andrew Kanter,,,,2012-11-11 20:45:05,2012-11-11 20:45:05,2014-05-23 13:48:33,shekhar,1,
ccd58683-61e1-4ad0-a067-f5cf6ff93e1b,40.193922,44.503984,American University of Armenia,http://www.aua.am/,Research,,0,0,0,Rubina Danilova,,,,2012-11-11 20:45:05,2012-11-11 20:45:05,0000-00-00 00:00:00,,1,
5cc7dd0c-be7f-4896-9511-661093a8eb34,18.468114612203,120.89378356934,Adams Ilocos Norte RHU,,Clinical,,0,0,0,National Telehealth Center,,CHITS with RxBox,,,2015-01-28 01:32:05,2015-01-28 01:32:05,shekhar,1,
a501cc4e-8915-422f-af8f-276fa7d5bda9,42.358433,-71.059776,Partners In Health,http://www.pih.org/,Research,,0,0,0,Michael Seaton,,,,2013-06-28 13:10:23,2012-11-11 20:45:05,2015-07-01 15:04:01,shekhar,1,2.2

admin table:

id,token,principal
1,shekhar,openmrs_id:shekhar

auth table:

id,atlas_id,principal,token,privileges,expires
1,04959f5e-da0f-4e5f-b5bd-2cd63db98052,openmrs_id:shekhar,shekhar,ALL,
2,6fd88911-93c7-4c75-af62-c3ec8044ea58,openmrs_id:shekhar,shekhar,ALL,
3,ccd58683-61e1-4ad0-a067-f5cf6ff93e1b,openmrs_id:shekhar,shekhar,ALL,
4,5cc7dd0c-be7f-4896-9511-661093a8eb34,openmrs_id:shekhar,shekhar,ALL,
5,a501cc4e-8915-422f-af8f-276fa7d5bda9,openmrs_id:shekhar,shekhar,ALL,
2 Likes

There also appears to be a starter SQL script here that may help or be an alternative.

2 Likes

Consider using mongo

Hey Shekhar,

I am assuming this is regarding data in atlas table. When you create a new marker site, its auth and privileges needs to be set up. One of the easy way to do so is to create site from UI. So the code will take care of inserting other relational data. Even a data with single marker site is enough to get started.

I sent burke a mysql data dump recently. He can probably give it to you, in private preferably :slight_smile:

i dont know where to post this, but Uganda looks like it is in Russia on the atlas… :frowning:

Is this the same pin that you are referring to. If so, it seems to be spam and unfortunately, the existing code don’t prevent this type of spam markers, I checked the RSS feed to find out the owner of that pin and figured out that with the existing code one can make his identity change/remove.

In the coming release we’ll address such issues. Thanks for raising this issue. :slight_smile:

The existing code is just bad all around to be honest. Literally the only nice thing is the map – the admin support is abysmal.