I’m exploring using the OHDSI vocabularies and concept relationships to map MedDRA PTs to corresponding ICD9CM codes.
When I map from MedDRA to ICD9CM using the “MedDRA – ICD9CM” concept_relationship, I am able to map 3966 of the approximately 12000 active MedDRA PTs to one or more ICD9 codes.
In an earlier post to this topic, @Christian_Reich mentioned that the “MedDRA – ICD9CM” relationships are not the preferred approach, so I’ve also tried mapping from MedDRA -> SNOMED -> ICD9CM (see below for the SQL query I’m using). That approach produces mappings for 3643 PTs.
As a check to make sure there isn’t a mapping directionality issue, I also tried a query going from ICD9CM -> SNOMED -> MedDRA. That query also yielded mappings for 3643 PTs.
Am I thinking about this the right way? Are there other ways to use the concepts and concept_relationships that might allow more MedDRA PT terms to be mapped?
SELECT c1.concept_code AS pt_code,
c3.concept_code AS icd9_code,
c3.concept_name AS icd9_desc,
c3.concept_class_id AS icd9_class
FROM
-- Restrict concept1 (c1) to MedDRA vocabulary
(SELECT *
FROM concept c1
WHERE c1.vocabulary_id = 'MedDRA' AND c1.concept_class_id = 'PT'
AND c1.valid_end_date > current_date) c1
-- Use the 'MedDRA - SNOMED eq' relationship to map from concept1 (MedDRA vocab)
-- to concept2 (SNOMED)
LEFT JOIN concept_relationship cr12
ON c1.concept_id = cr12.concept_id_1
AND cr12.relationship_id IN ('MedDRA - SNOMED eq')
AND cr12.valid_end_date > current_date
-- Left join with concept (c2) to decode the attributes for concept2
LEFT JOIN concept c2
ON cr12.concept_id_2 = c2.concept_id AND c2.valid_end_date > current_date
-- Left join using the 'Mapped from' relationship to map from concept2 (SNOMED vocab)
-- to concept3 (ICD9CM vocab)
LEFT JOIN concept_relationship cr23
ON c2.concept_id = cr23.concept_id_1
AND cr23.relationship_id IN ('Mapped from')
AND cr23.valid_end_date > current_date
-- Left join with concept (c3) to decode the attributes for concept3
LEFT JOIN concept c3
ON cr23.concept_id_2 = c3.concept_id AND c3.vocabulary_id = 'ICD9CM'
AND c3.valid_end_date > current_date