Search code examples
snomed-ct

Does SNOMED provide upgrade maps for code that have become inactive?


It seems that the SNOMED codeset is rapidly evolving. New codes are being added, old codes are being deactivated. Do the releases provide upgrade maps from old code to new codes? (In particular, I'm interested in the UK extension).


Solution

  • Yes.

    The information you're after will be in two files.

    1. Concept inactivation indicator reference set This reference set will tell you why a concept was inactivated. E.g. Duplicate, Erroneous, Outdated Etc. The referencedComponentId is the concept that was inactivated. The files are all IDs so you'll need to lookup the human readable terms. Specifications are here 5.2.3 Attribute Value Reference Set
    2. Historical association reference set Not this refset itself, but it's subtypes, will be the mapping you are looking for. Each reference set provides a specific association as required. For example."SAME AS association reference set" provides the mappings for duplicate concepts. The referencedComponentId is the inactive concept (X) and the targetComponentId is the association (Y). Read as "X SAME AS Y" 5.2.5 Association Reference Set

    As a holistic example: 247702001|Bad trips (finding)| is a retired concept. Has the following entries in the above reference sets

    |8c7497f7-8230-4d01-9967-c85dd6f57e46|...|247702001|900000000000482003(Duplicate)|
    |d09da0d7-b8f9-4d07-9b28-5c74ab247cb1|...|247702001|28368009(Psychoactive substance-induced organic hallucinosis)|
    

    Presumably you've got the RF2 snapshot in a database? My advice is to create a table or view, of the three tables joined.

    select * from concepts
    left join conceptInactivationRefset 
         on concepts.id = conceptInactivationRefset.referencedComponentId
    left join SAMEASrefset 
         on concepts.id = SAMEASrefset.referencedComponentId
    where conceptInactivationRefset.active = 1 and SAMEASrefset.active = 1;
    

    That should give you a start.