For a Reference element whose targetProfile lists more than one profile (here: the abstract base http://hl7.org/fhir/StructureDefinition/DocumentReference and the derived http://nictiz.nl/fhir/StructureDefinition/IHE.MHD.Minimal.DocumentReference), where the referenced resource actually conforms to both, SDK 6 reports an error instead of accepting the match.
- validator.fhir.org (Java reference validator): Warning — "Found multiple matching profiles for urn:uuid:... among choices: [base DocumentReference], [Nictiz Minimal DocumentReference]". This is informational: it confirms the resource conforms to both candidates and just flags that it can't tell which one was intended as primary.
- SDK 6: Invalid Content (error) — "Referenced resource '' does not validate against any of the expected target profiles (...)." Note the blank resource identity ('') in the message — it looks like whatever code path is meant to report which resource/profile it resolved to never completes.
Per the FHIR spec, Reference.targetProfile is 0..*, and when multiple profiles are listed, conformance to any one of them satisfies the reference (OR semantics, not AND). The resource here matches both — so per spec this should validate successfully, at most with an informational note about the ambiguity (as java does).
For a Reference element whose targetProfile lists more than one profile (here: the abstract base http://hl7.org/fhir/StructureDefinition/DocumentReference and the derived http://nictiz.nl/fhir/StructureDefinition/IHE.MHD.Minimal.DocumentReference), where the referenced resource actually conforms to both, SDK 6 reports an error instead of accepting the match.
Per the FHIR spec, Reference.targetProfile is 0..*, and when multiple profiles are listed, conformance to any one of them satisfies the reference (OR semantics, not AND). The resource here matches both — so per spec this should validate successfully, at most with an informational note about the ambiguity (as java does).