Hello, I'm Moisés Cedeño. It's a pleasure to greet you all.
First of all,
thank you for maintaining and suspporting this community.
Secondly, I would like to get some help with an error that I'm still having after trying to resolve it. I'm encountering a C-CDA MDHT Conformance Error with the sdtc:patient element placement in patientRole that I haven't been able to resolve after reviewing available documentation and sample files.
Error:C-CDA MDHT Conformance Error - cvc-complex-type.2.4.a: Invalid content was found starting with element '{"urn:hl7-org:sdtc":patient}'. One of '{"urn:hl7-org:v3":telecom, "urn:hl7-org:v3":patient, "urn:hl7-org:v3":providerOrganization}' is expected.
Line Number: Line number not availableCurrent Structure:
<patientRole>
<id extension="0332000001" root="2.16.840.1.113883.19.5"/>
<addr use="HP">...</addr>
<telecom use="HP" value="tel:+1(555)723-1544" />
<telecom use="MC" value="tel:+1(555)777-1234" />
<telecom value="mailto:..." use="HP" />
<sdtc:patient>
<sdtc:id extension="0332000001" root="2.16.840.1.113883.19.5" />
</sdtc:patient>
<patient>...</patient>
<providerOrganization>...</providerOrganization>
</patientRole>
What I have tried:
- Reviewed official C-CDA sample files (including 170.315_b1_toc_amb_ccd_r11_svap_uscdiv3_sample1_v1.xml) — the sample declares xmlns:sdtc="urn:hl7-org:sdtc" but does NOT include sdtc:patient in patientRole.
- Compared XML headers and namespace declarations with official samples.
- Reviewed C-CDA R2.1 Implementation Guide and HL7 CDA R2 schema definitions
- Tested different sdtc:patient positions:
- After <providerOrganization> (end of patientRole) — Schema error
- After <patient> and before <providerOrganization> — Schema error
- After <telecom> and before <patient> — Schema error
Question:
What is the correct position for sdtc:patient within patientRole according to the C-CDA R2.1 schema? If sdtc:patient is not allowed in patientRole, should I remove it entirely, or is there an alternative structure for including SDTC patient extensions?
Attachments:
- CCDA_a-000001_TEST_8.xml — file XML I am trying to validate
- CCDA_a-000001_Fixed_8 - Findings — validation findings/error details
- Screenshot 1: Selected validation case in the validation tool
- Screenshot 2: Validation tool error screen showing the error
Thank you for your time and assistance,
Moisés