I’m working on some vocabulary browsing tools and poking around the vocabulary tables. I’m wondering if anyone can explain this to me.
The relationship
table has two mostly redundant columns:
relationship_name
relationship_concept_id
For 381 of the 388 rows in relationship
, the concept_name
related to the relationship_concept_id
is the same as the relationship_name
, but 7 rows have different values:
select row_number() over (order by 1,2) as rn,
r.relationship_name,
c.concept_name
from :cdm.relationship r
join :cdm.concept c on r.relationship_concept_id = c.concept_id
where r.relationship_name != c.concept_name;
rn | relationship_name | concept_name
----+---------------------------------------------+---------------------------------------------------
1 | ATC to RxNorm (RxNorm) | ATC to RxNorm (FDB)
2 | ICD-9-Procedure to SNOMED equivalent (OMOP) | ICD9 procedure to SNOMED equivalent (OMOP)
3 | Standard to Non-standard map (OMOP) | Mapping relationship from Standard Concept (OMOP)
4 | Non-standard to Standard map (OMOP) | Mapping relationship to Standard Concept (OMOP)
5 | RxNorm to ATC (RxNorm) | RxNorm to ATC (FDB)
6 | RxNorm to SNOMED equivalent (RxNorm) | RxNorm to SNOMED equivalent (RxNorm)
7 | SNOMED to ICD-9-Procedure equivalent (OMOP) | SNOMED to ICD9 procedure equivalent (OMOP)
For rows 2, 6 and 7 the differences are purely typographical inconsistencies and should be fixed. Rows 3 and 4 seem to be insubstantial differences in phrasing and should also probably be reconciled. Rows 1 and 5 seem to be disagreements about the source of the relationship, and maybe one of these is right and the other is wrong.
So, when I started composing this email I was going to ask whether there was a reason for these redundant fields and if the small number of inconsistencies were meaningful. But looking more closely it appears the inconsistencies are not meaningful and could be fixed. And, if they are fixed, is there any reason to retain the redundant fields? Presumably the one we should get rid of is relationship_concept_id
.
(I was going to post this to Vocab Users, but I guess it belongs in CDM Builders?)