OHDSI Home | Forums | Wiki | Github

How do I set up multiple data sources in Atlas


(Jay Boyer) #1

I have successfully set up Atlas with the Synpuf5 data. I am using an Oracle backend. I would like to set up 2 additional data sources.

I have my original schema containing the synpuf5 data named SYNPUF5
and two additional schemas contain sample data named OMOP_NOTSPIKED and OMOP_SPIKED. Each of these schemas contains a full data set including vocabulary.

My initial data for the SOURCE and SOURCE_DAIMON tables was set as follows:

INSERT INTO OHDSI.source (source_id, source_name, source_key, source_connection, source_dialect)
VALUES (1, ‘cdm synpuf5’, ‘CDM_SOURCE’, ‘jdbc:oracle:thin:{adm_user/adm_pw}@{db_url}:1521/ORCL’, ‘oracle’);
INSERT INTO OHDSI.source (source_id, source_name, source_key, source_connection, source_dialect)
VALUES (2, ‘Default vocabulary’, ‘VOCABULARY’, ‘jdbc:oracle:thin:{adm_user/adm_pw}@{db_url}:1521/ORCL’, ‘oracle’);

INSERT INTO OHDSI.source_daimon (source_daimon_id, source_id, daimon_type, table_qualifier, priority)
VALUES (1,1,0, ‘SYNPUF5’, 0);
INSERT INTO OHDSI.source_daimon (source_daimon_id, source_id, daimon_type, table_qualifier, priority)
VALUES (2,1,1, ‘VOCABULARY’, 0);
INSERT INTO OHDSI.source_daimon (source_daimon_id, source_id, daimon_type, table_qualifier, priority)
VALUES (3,1,2, ‘RESULTS’, 0);
INSERT INTO OHDSI.source_daimon (source_daimon_id, source_id, daimon_type, table_qualifier, priority)
VALUES (4,2,1, ‘VOCABULARY’, 1);

And this works. The single source “cdm synpuf5” show up as expected in the data source list.

To add my two additional sources I added to the SOURCE and SOURCE_DAIMON tables as follows:
(Note that I had the change the source table name for CDM_SOURCE in my 2 new schemas because of unique key constraints on the source_name.)

INSERT INTO OHDSI.source (source_id, source_name, source_key, source_connection, source_dialect)
VALUES (3, ‘cdm not spiked’, ‘CDM_SOURCE_ONS’, ‘jdbc:oracle:thin:{adm_user/adm_pw}@{db_url}:1521/ORCL’, ‘oracle’);

INSERT INTO OHDSI.source_daimon (source_daimon_id, source_id, daimon_type, table_qualifier, priority)
VALUES (5,3,0, ‘OMOP_NOTSPIKED’, 0);
INSERT INTO OHDSI.source_daimon (source_daimon_id, source_id, daimon_type, table_qualifier, priority)
VALUES (6,3,1, ‘VOCABULARY’, 0);
INSERT INTO OHDSI.source_daimon (source_daimon_id, source_id, daimon_type, table_qualifier, priority)
VALUES (7,3,2, ‘RESULTS_OMOP_NOT_SPIKED’, 0);

INSERT INTO OHDSI.source (source_id, source_name, source_key, source_connection, source_dialect)
VALUES (4, ‘cdm spiked’, ‘CDM_SOURCE_OS’, ‘jdbc:oracle:thin:{adm_user/adm_pw}@{db_url}:1521/ORCL’, ‘oracle’);

INSERT INTO OHDSI.source_daimon (source_daimon_id, source_id, daimon_type, table_qualifier, priority)
VALUES (8,4,0, ‘OMOP_SPIKED’, 0);
INSERT INTO OHDSI.source_daimon (source_daimon_id, source_id, daimon_type, table_qualifier, priority)
VALUES (9,4,1, ‘VOCABULARY’, 0);
INSERT INTO OHDSI.source_daimon (source_daimon_id, source_id, daimon_type, table_qualifier, priority)
VALUES (10,4,2, ‘RESULTS_OMOP_SPIKED’, 0);

In Atlas I see the new data source names but when I select one of them I get an error when I try to generate a report. The error message simply says “! error loading report”.

I thought I was seting up the daimon/daimon_source table data correctly for the 2 additional sources but clearly I misunderstood something in the documentation.

How should I modify my setup so that the additional data sources work correctly.

thanks,

Jay


t