Hello Everyone,
I have a question regarding vocabulary updates. so thought I will check with you folks. Request you to help me if you have time. Currently our data is all uploaded and vocab is updated to Jan 2020 version. However during Vocab updates, we have to drop few constraints as it was causing issues while vocab file uploads. Though I followed the order of tables from github for vocab upload, the error still occurs. I guess this issue is discussed in forum as well.
But now when I try to update the constraints based on this https://github.com/OHDSI/DDLgeneratr/blob/master/inst/sql/sql_server/OMOP%20CDM%20constraints.sql, I still see some issues due to missing concepts. Meaning concept is present in concept_relationship table but missing in concept table. So it violates the foreign key constraint. Can anyone help me with this?
Whether I upload data first and define constraints or the other way round, the issue still prevails. Any suggestions on how can I get rid of this error? For example, the error looks like as shown below
“ERROR: insert or update on table “concept_relationship” violates foreign key constraint “fpk_concept_relationship_c_1” DETAIL: Key (concept_id_1)=(2108888) is not present in table “concept”. SQL state: 23503”
Can someone help with this? How do you handle this issue at your site?