Stream: IG creation
Topic: error - has children and multiple types
Sean McIlvenna (Aug 13 2018 at 22:33):
I'm getting an error from the IG Publisher:
Observation.valueQuantity has children (Observation.valueQuantity.value) and multiple types (Quantity, CodeableConcept, string, boolean, Range, Ratio, SampledData, Attachment, time, dateTime, Period) in profile BloodPressureObservation.valueQuantity
Sean McIlvenna (Aug 13 2018 at 22:33):
Any idea how to fix this?
Sean McIlvenna (Aug 13 2018 at 22:34):
I've tried restricting the <type> on valueQuantity to just "Quantity"
Sean McIlvenna (Aug 13 2018 at 22:34):
but that didn't help
Lloyd McKenzie (Aug 13 2018 at 22:50):
I think you need to first slice on type, then constrain your slice.
Sean McIlvenna (Aug 13 2018 at 22:51):
this is what I have
Sean McIlvenna (Aug 13 2018 at 22:51):
<element id="value[x]">
<path value="Observation.value[x]"/>
<slicing>
<discriminator>
<type value="value"/>
<path value="@type"/>
</discriminator>
<rules value="open"/>
</slicing>
<short value="value[x]"/>
<definition
value="SHALL contain exactly one [1..1] value[x], where value[x] is (CONF:4383-273)"/>
<min value="1"/>
<max value="1"/>
</element>
<element id="value[x].valueQuantity:quantity">
<path value="Observation.valueQuantity"/>
<sliceName value="quantity" />
<short value="valueQuantity"/>
<definition value="valueQuantity (CONF:4383-274)"/>
<type>
<code value="Quantity" />
</type>
</element>
<element id="value[x].valueQuantity:quantity.value">
<path value="Observation.valueQuantity.value"/>
<sliceName value="quantity" />
<short value="value"/>
<definition value="SHALL contain exactly one [1..1] value (CONF:4383-281)."/>
<min value="1"/>
<max value="1"/>
</element>
<element id="value[x].valueQuantity:quantity.unit">
<sliceName value="quantity" />
<path value="Observation.valueQuantity.unit"/>
<short value="unit"/>
<definition value="SHALL contain exactly one [1..1] unit (CONF:4383-282)."/>
<min value="1"/>
<max value="1"/>
</element>
Sean McIlvenna (Aug 13 2018 at 22:52):
still gives that error...
Sean McIlvenna (Aug 13 2018 at 22:53):
regardless of whether I put <type> on value[x] or value[x].valueQuantity
Lloyd McKenzie (Aug 13 2018 at 22:53):
Why are you slicing by value?
Sean McIlvenna (Aug 13 2018 at 22:53):
oh.. i see what you mean
Sean McIlvenna (Aug 13 2018 at 22:53):
ok, good point. I'll try to change that
Sean McIlvenna (Aug 13 2018 at 22:57):
ok. changed it to slice by "type" with path "$this"
Sean McIlvenna (Aug 13 2018 at 22:57):
same error
Sean McIlvenna (Aug 13 2018 at 23:01):
I keep trying different variations, and nothing is working... =/
Sean McIlvenna (Aug 13 2018 at 23:01):
just trying to figure out how to require .value and .unit on a valueQuantity in an Observation...
Lloyd McKenzie (Aug 13 2018 at 23:03):
What happens in the vital signs profiles?
Eric Haas (Aug 14 2018 at 00:00):
I do not think you are able to slice by anything other that value in the spreadsheets.
Lloyd McKenzie (Aug 14 2018 at 00:04):
You can slice by anything in the spreadsheets. Just append .@type, .@pattern, etc. to your discriminator
Grahame Grieve (Aug 14 2018 at 06:02):
is this sorted?
Sean McIlvenna (Aug 14 2018 at 21:48):
I believe this is a bug in the older version of the ig publisher that I was using... now I'm getting different errors, having downloaded the latest ig publisher
Sean McIlvenna (Aug 14 2018 at 21:48):
will confirm once I know for sure
Last updated: Apr 12 2022 at 19:14 UTC