DV_CODED_TEXT internal/external codes

Hello everyone,

Maybe it is a dumb question, but I am a bit confused about this. When using a DV_CODED_TEXT element, in the archetype designer, I have the possibility of using internal or external values. I guess that I should use internal codes in case that I have “local” set values, and external codes in case I would like to use external lists/set of values somehow (terminologies?), but I would like someone to reaffirm or, in case I am wrong, to give me the correct answer about that.

I just want to verify it in order to align our strategy when creating archetypes/templates with the rest of you, since I didn’t find any information about this anywhere.

Thanks a lot in advance!


Hi Laura! You’re right, you use internal codes for when the archetype should define the value set. Those codes will get an atXXXX code, and not for example a SNOMED CT code. Internal coded values can only be added to an archetype, and not to a template.

External codes are, as you say, codes from an external terminology. When you use an external terminology, it can be included using an URI or put directly in the archetype or template. External terminology value sets need a name for the terminology or value set, for example “SNOMED-CT”. I suspect the most common of these are standardised somewhere, but I don’t know where (@sebastian.iancu?)

Thanks a lot for the answer, @siljelb . Now I am confused between the difference of adding an external code of a terminology in that way or, in the other hand, to bind a value/element to a terminology by adding, first, the terminology in the “Languages and Terminologies” part and then include a binding of each element and adding the corresponding code.

1 Like

Another good question! The main differences are that internal codes make archetypes self-contained, and the persisted code is “atXXXX” and not for example the SNOMED CT code. I’m not 100% sure about this, but I think that to use the term bindings of a value set on persisted data, you need to look up the bindings (=mappings) between internal at-codes and external terminologies in the archetype.

The value relates to TERMINOLOGY_ID type definition and they are described by terminology identifiers in Base Types.
If I remember correctly, Archetype Editor provided a list like that.

1 Like

As @siljelb also commented; using terminology binding is about metadata. This is not stored in the EHR. The value set, defined either local in the archetype or the template, or as a external look up is stored in the EHR. Or more precisely; the selected value(s) are stored in the EHR.

Terminology bindings in the archetypes provides a great opportunity to describe clinical concept and attributes at design time. They can be used to add metadata relevant for integrations.

1 Like