Documentation
Common Data Model (CDM)
Convert Database to CDM (ETL)
Tool Specific Documentation
Common Data Model (CDM)
Convert Database to CDM (ETL)
Tool Specific Documentation
All WebAPI documentation has moved to GitHub. Please disregard the content below as it is legacy and kept for posterity.
A given institution implementing a CDM may have more than one datasets in CDM. A research may want to execute an OHDSI study on multiple CDM datasets and data and result schema should not refer to conflicting table names.
This wiki page documents a configuration that is most common at many implementing institution.
For example, a read-only schema with CDM data (e.g., person table, measurement table) may be in schema `dataA`. To allow (for example for Achilles) to write to result tables (e.g., achilles_results table), a corresponding schema (with write privileges) would be `dataA_results`.
The convention is that OHDSI software tools or studies do not try to manage various datasets (e.g., by columns in result tables (column for dataset in achilles_results table (for exmaple)). Instead, they rely on separation of results by simply separate database result schemas for each dataset.
ADDITION: So, if you have a CDM in schema 'dataA' and it is read-only, you can create a new schema 'dataA_results' that is writable, and when you execute Achilles, specify dataA as the cdm_database_schema and dataA_results as the results_database_schema.
Example setup for multiple datasets:
data schema,results schema --------------------------- dataA,dataA_results dataB,dataB_results
In the single CDM setup, it's common to use the tables created in the WebAPI schema as the results schema for the CDM. Once additional CDMs are introduced, it's necessary to deploy specific tables to each CDM result schema hosted on each CDM database. The following tables can be exported from the WebAPI schema and deployed into the CDM result schema:
cohort | heracles_analysis |
COHORT_FEATURES | feas_study_result |
COHORT_FEATURES_DIST | feas_study_index_stats |
COHORT_FEATURES_REF | heracles_heel_results |
COHORT_FEATURES_ANALYSIS_REF | heracles_results |
cohort_inclusion | heracles_results_dist |
cohort_inclusion_result | ir_analysis_dist |
cohort_inclusion_stats | ir_analysis_strata_stats |
cohort_summary_stats | ir_analysis_result |
feas_study_inclusion_stats | ir_strata |
To find this DDL, explore your local WebAPI database schema, and use the tool (example, pgAdmin for Postgresql) to export the DDL and execute on each CDM.