Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SchemaUpdate.java f_* tables #113

Open
cnmaier opened this issue Jun 7, 2017 · 1 comment
Open

SchemaUpdate.java f_* tables #113

cnmaier opened this issue Jun 7, 2017 · 1 comment

Comments

@cnmaier
Copy link

cnmaier commented Jun 7, 2017

I am currently trying to set up your project with a standard installation of OMOP synpuf_cdm, however getting some errors on startup of the webapp:

2017-06-07 10:27:28.816 [localhost-startStop-1] ERROR o.h.tool.hbm2ddl.SchemaUpdate [SchemaUpdate.java:261] HHH000388: Unsuccessful: alter table condition_occurrence add constraint FK_l6vpcrfg21weo25qrnys952o1 foreign key (person_id) references f_person 2017-06-07 10:27:28.819 [localhost-startStop-1] ERROR o.h.tool.hbm2ddl.SchemaUpdate [SchemaUpdate.java:262] FEHLER: Einfügen oder Aktualisieren in Tabelle »condition_occurrence« verletzt Fremdschlüssel-Constraint »fk_l6vpcrfg21weo25qrnys952o1« **Detail: Key (person_id)=(453) is not present in »f_person« table.** 2017-06-07 10:27:28.822 [localhost-startStop-1] ERROR o.h.tool.hbm2ddl.SchemaUpdate [SchemaUpdate.java:261] HHH000388: Unsuccessful: alter table drug_exposure add constraint FK_pdjbpw6cpigr8oky0qjw25pxv foreign key (person_id) references f_person 2017-06-07 10:27:28.823 [localhost-startStop-1] ERROR o.h.tool.hbm2ddl.SchemaUpdate [SchemaUpdate.java:262] FEHLER: Einfügen oder Aktualisieren in Tabelle »drug_exposure« verletzt Fremdschlüssel-Constraint »fk_pdjbpw6cpigr8oky0qjw25pxv« Detail: Schlüssel (person_id)=(1172) ist nicht in Tabelle »f_person« vorhanden. 2017-06-07 10:27:28.828 [localhost-startStop-1] ERROR o.h.tool.hbm2ddl.SchemaUpdate [SchemaUpdate.java:261] HHH000388: Unsuccessful: alter table measurement add constraint FK_dwj6jftl6o0bb3v781tfnxhmd foreign key (person_id) references f_person 2017-06-07 10:27:28.830 [localhost-startStop-1] ERROR o.h.tool.hbm2ddl.SchemaUpdate [SchemaUpdate.java:262] FEHLER: Einfügen oder Aktualisieren in Tabelle »measurement« verletzt Fremdschlüssel-Constraint »fk_dwj6jftl6o0bb3v781tfnxhmd« Detail: Schlüssel (person_id)=(1265) ist nicht in Tabelle »f_person« vorhanden. 2017-06-07 10:27:28.832 [localhost-startStop-1] ERROR o.h.tool.hbm2ddl.SchemaUpdate [SchemaUpdate.java:261] HHH000388: Unsuccessful: alter table observation add constraint FK_2icte14g0f0j42nmrovgy8ptu foreign key (person_id) references f_person 2017-06-07 10:27:28.834 [localhost-startStop-1] ERROR o.h.tool.hbm2ddl.SchemaUpdate [SchemaUpdate.java:262] FEHLER: Einfügen oder Aktualisieren in Tabelle »observation« verletzt Fremdschlüssel-Constraint »fk_2icte14g0f0j42nmrovgy8ptu« Detail: Schlüssel (person_id)=(575) ist nicht in Tabelle »f_person« vorhanden. 2017-06-07 10:27:28.836 [localhost-startStop-1] ERROR o.h.tool.hbm2ddl.SchemaUpdate [SchemaUpdate.java:261] HHH000388: Unsuccessful: alter table procedure_occurrence add constraint FK_74ijltvx1uofohc2un9aolesw foreign key (person_id) references f_person 2017-06-07 10:27:28.837 [localhost-startStop-1] ERROR o.h.tool.hbm2ddl.SchemaUpdate [SchemaUpdate.java:262] FEHLER: Einfügen oder Aktualisieren in Tabelle »procedure_occurrence« verletzt Fremdschlüssel-Constraint »fk_74ijltvx1uofohc2un9aolesw« Detail: Schlüssel (person_id)=(941) ist nicht in Tabelle »f_person« vorhanden. 2017-06-07 10:27:30.016 [localhost-startStop-1] ERROR o.h.tool.hbm2ddl.SchemaUpdate [SchemaUpdate.java:261] HHH000388: Unsuccessful: alter table procedure_occurrence add constraint FK_nw5almj02oo3rjl54xyhiyup3 foreign key (procedure_concept_id) references concept 2017-06-07 10:27:30.017 [localhost-startStop-1] ERROR o.h.tool.hbm2ddl.SchemaUpdate [SchemaUpdate.java:262] FEHLER: Einfügen oder Aktualisieren in Tabelle »procedure_occurrence« verletzt Fremdschlüssel-Constraint »fk_nw5almj02oo3rjl54xyhiyup3« Detail: Schlüssel (procedure_concept_id)=(2211506) ist nicht in Tabelle »concept« vorhanden. 2017-06-07 10:27:31.118 [localhost-startStop-1] ERROR o.h.tool.hbm2ddl.SchemaUpdate [SchemaUpdate.java:261] HHH000388: Unsuccessful: alter table procedure_occurrence add constraint FK_imqm99ym8fl0jmlbh7rg0ew3l foreign key (procedure_source_concept_id) references concept 2017-06-07 10:27:31.121 [localhost-startStop-1] ERROR o.h.tool.hbm2ddl.SchemaUpdate [SchemaUpdate.java:262] FEHLER: Einfügen oder Aktualisieren in Tabelle »procedure_occurrence« verletzt Fremdschlüssel-Constraint »fk_imqm99ym8fl0jmlbh7rg0ew3l« Detail: Schlüssel (procedure_source_concept_id)=(2211506) ist nicht in Tabelle »concept« vorhanden. 2017-06-07 10:27:31.123 [localhost-startStop-1] ERROR o.h.tool.hbm2ddl.SchemaUpdate [SchemaUpdate.java:261] HHH000388: Unsuccessful: alter table visit_occurrence add constraint FK_gssbuvh60shtinbnlm07ygaer foreign key (person_id) references f_person 2017-06-07 10:27:31.123 [localhost-startStop-1] ERROR o.h.tool.hbm2ddl.SchemaUpdate [SchemaUpdate.java:262] FEHLER: Einfügen oder Aktualisieren in Tabelle »visit_occurrence« verletzt Fremdschlüssel-Constraint »fk_gssbuvh60shtinbnlm07ygaer« Detail: Schlüssel (person_id)=(71) ist nicht in Tabelle »f_person« vorhanden. 2017-06-07 10:27:31.124 [localhost-startStop-1] INFO o.h.tool.hbm2ddl.SchemaUpdate [SchemaUpdate.java:267] HHH000232: Schema update complete

It appears that the f_* (and probably the aud (?)) tables need to be filled with data, so that the foreign key constraints in the OMOP CDM tables can be created. The f tables, however, are empty. So, do I have to fill them by myself?

When trying to query a patient on the frontend I do not get any results, although it is definitely in the CDM database. This is why I thought the errors above would be the reason.

@myungchoi
Copy link
Contributor

f_person table must be populated. It's one-to-one table with person table. OMOP does not have person demographic information. You will need to assign them for each person in the f_person table.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants