Stream: conformance
Topic: Binding CodeableConcept at different levels
Morten Ernebjerg (Jan 15 2019 at 14:46):
I am working on a profile (in Forge) and want to introduce a ValueSet binding for the allowed codes in a fieldof type CodeableConcept. A binding could be added at three levels:
1. Field itself (X)
2. coding (X.coding)
3. coding.code field (X.coding.code)
Looking at examples, it seems most common to have a binding to the field itself (case 1). However, the bound ValueSet often looks (to a casual observer, at least) like smt. that could equally well be bound to coding.code (case 3), namely a list of codes. Actually, I suppose it is generally not quite clear to me how ValueSet bindings work for fields with a complex data type (since the codes would then seem to also have to be complex objects).
A particular case I was pondering is when the ValueSet corresponds to all codes from a single coding system. It seems that is also often covered with a binding to the whole field (X), but I would have thought the more precise thing would be to fix X.coding.system to the relevant system and then bind a ValueSet to X.coding.code.
Is there some guidance/discussion of this available? (didn't find any yet)
Lloyd McKenzie (Jan 15 2019 at 14:56):
Bind to the top level unless you need multiple bindings, in which case put the "main" binding at the top level and then slice CodeableConcept.coding and define additional bindings on each slice. Never bind to coding.code as the binding needs to take into account both the code + system. Bindings on "code" should only occur for elements that only have a type of code
- e.g. Patient.gender
Simone Heckmann (Jan 15 2019 at 17:26):
Consider that a required binding on top level requires only one instance of coding to comply to the given ValueSet, whereas doing it on a lower level (without slicing ) requires all instances of coding to comply to the binding.
Lloyd McKenzie (Jan 15 2019 at 19:25):
Which is why you do it on the lower level, it should always be with slicing :)
Morten Ernebjerg (Jan 16 2019 at 07:14):
Thanks a lot, that cleared up several things for me!
Last updated: Apr 12 2022 at 19:14 UTC