FHIR Chat · Value Set versus Code System OIDs · terminology

Stream: terminology

Topic: Value Set versus Code System OIDs


view this post on Zulip John Snyder (Mar 04 2020 at 15:29):

In the FHIR specification there are both Value Set OIDs and Code System OIDs. It appears the content associated with both OIDs is identical. For example:

Administrative Gender
• Value Set:
o URL: http://hl7.org/fhir/R4/valueset-administrative-gender.html
o OID: 2.16.840.1.113883.4.642.3.1
• Code System:
o URL: http://hl7.org/fhir/R4/codesystem-administrative-gender.html
o OID: 2.16.840.1.113883.4.642.4.2

Questions:

  1. When constructing a FHIR based message, using the URN format (e.g. urn:oid: 2.16.840.1.113883.4.642.3.1), which OID should be referenced?
  2. Is there a reason that most of the FHIR OIDs are not represented in the HL7 OID Registry for verification/validation purposes that the OID is unique?

Thanks
John

view this post on Zulip Lloyd McKenzie (Mar 04 2020 at 17:22):

  1. You're not allowed to use the urn format. All FHIR code systems have canonical URLs and you must use the defined URLs. The OIDs are provided for those who need to convert FHIR instances into v3 or something else that requires OIDs. You must always use the URL for the code system. The value set defines a subset of codes from one or more code systems, but doesn't define any meaning. In some cases, the value set happens to include all codes from a given code system, but that can change over time and isn't guaranteed. The code system is where the code is defined and the combination of code + system gives you mandator meaning.
  2. We may get the OIDs for FHIR code systems into the OID registry at some point, but it's not a high priority (in part because the OIDs only matter to someone converting FHIR to v3 and there aren't many folks doing that). We know they're unique because the root for the OIDs is fixed and we manage the issuing of the sub-OIDs. (Though there have been tooling issues that resulted in incorrect OIDs in some of the older FHIR releases.)

view this post on Zulip Lloyd McKenzie (Mar 04 2020 at 17:26):

As a general rule, even when you have the option of using the urn:oid: approach to identifying a code system in FHIR (because it's a local code system you've defined rather than one that HL7 has defined), you shouldn't. OIDs are not human-friendly or resolvable. Our objective with FHIR is to make the instances clearly understandable to software developers. Proper URLs are much better for that purpose. The NamingSystem resource makes translation straightforward if you're in an environment where you need to handle both v3 (e.g. CDA) and FHIR. You'll need that translation infrastructure in place regardless to handle all of the places where FHIR mandates the use of URLs for code systems that are used with OIDs in v3 (e.g. all of the HL7 v3 code systems, LOINC, SNOMED, ICD-10, etc.)

view this post on Zulip John Snyder (Mar 05 2020 at 17:29):

Thanks Lloyd,

I could be totally misunderstanding, but if the URN format is not allowed, then why is it being displayed in the FHIR SPEC?

For example: http://hl7.org/fhir/us/core/STU3/ValueSet-omb-race-category.html

From what I can see, there isn't a canonical URL available for the OMB Race Category, or am I missing it?

Thanks
John

view this post on Zulip Lloyd McKenzie (Mar 05 2020 at 18:37):

I didn't say it wasn't allowed period, it's not allowed if there's a defined URL. So LOINC must always be identified by "http://loinc.org", never by OID - even though it has one. For local code systems, you can use a urn:oid if you wish - it's legal. However, it's also a discouraged practice. If you need a standard way to refer to a non-local code system, submit a change request to ask for a URL to be assigned.

view this post on Zulip John Snyder (Mar 05 2020 at 19:24):

Thank you. I understand the URN usage a bit better now.

We will be going from FHIR to V3, so should we use the code system OID or the Value Set OID in the V3 output?

view this post on Zulip Grahame Grieve (Mar 05 2020 at 20:38):

where in the v3 output? codeSystemVersion or valueSetVersion?

view this post on Zulip Grahame Grieve (Mar 05 2020 at 20:38):

or somewhere else?

view this post on Zulip John Snyder (Mar 05 2020 at 21:27):

Grahame Grieve
It would be when we populate the C-CDA with a V3 value set.

view this post on Zulip Lloyd McKenzie (Mar 05 2020 at 21:30):

If you're going from v3 to FHIR, you must translate code system OIDs to URLs if a standard URL exists. (Which one will for all v3 code systems and most common code systems like LOINC, SNOMED, etc.) If you don't, you're non-conformant with the FHIR spec. For local code systems you have OIDs for, you SHOULD create URLs and perform translations anyhow, but it's legal to use urn:oid:xxx. (If you stick with OIDs, you're saving a tiny amount on transformation and incurring a long-term cost for everyone on maintainability.)

view this post on Zulip Lloyd McKenzie (Mar 05 2020 at 21:32):

Value sets aren't generally declared in FHIR instances. The Coding.system always refers to the code system. The value set can be sent in an extension, but that's uncommon and can't be used to infer meaning.

view this post on Zulip Grahame Grieve (Mar 05 2020 at 21:39):

we populate the C-CDA with a V3 value set

yep, so you use codeSystem and the valueSet extension for the code system and value set OIDs respectively


Last updated: Apr 12 2022 at 19:14 UTC