if (hmis:SourceType/text()!='1') then boolean(hmis:SourceName) else true()
if (hmis:SourceType/text()='1') then boolean(hmis:SourceID) else true()
Source
<xs:element name="Source" type="hmis:source" minOccurs="1" maxOccurs="unbounded"><xs:annotation><xs:documentation xml:lang="en">A description of what software provider and organization are sending this XML information. Many sources can be grouped together into one XML file.</xs:documentation></xs:annotation></xs:element>
<xs:complexType name="sources"><xs:sequence><xs:element name="Source" type="hmis:source" minOccurs="1" maxOccurs="unbounded"><xs:annotation><xs:documentation xml:lang="en">A description of what software provider and organization are sending this XML information. Many sources can be grouped together into one XML file.</xs:documentation></xs:annotation></xs:element></xs:sequence></xs:complexType>