At most one CountrySubDivisionName

Error FX-SCH-A-000723 Factur-X

Element 'ram:CountrySubDivisionName' may occur at maximum 1 times.

Mandatory rule: As long as it is violated, the invoice is invalid and will be rejected by validators.
What is wrong

CountrySubDivisionName occurs more than once in PostalTradeAddress. This element may appear at most once in the postal address.

What the rule means

The rule limits the number of country subdivision entries in this postal address to one.

Please include no more than one country subdivision in the postal address

CountrySubDivisionName appears more than once in the end user's postal address. You can adjust the entries so that this element occurs no more than once.

What to do
  1. Find CountrySubDivisionName in the relevant PostalTradeAddress.
  2. Remove any extra occurrences so that no more than one element remains.
  3. Generate the invoice again and validate it again.
What it looks like
✗ Triggers the message
<ram:PostalTradeAddress>
  <ram:CountrySubDivisionName>Nord</ram:CountrySubDivisionName>
  <ram:CountrySubDivisionName>Est</ram:CountrySubDivisionName>
</ram:PostalTradeAddress>
✓ Correct
<ram:PostalTradeAddress>
  <ram:CountrySubDivisionName>Nord</ram:CountrySubDivisionName>
</ram:PostalTradeAddress>
Technical details

The Schematron test counts the direct ram:CountrySubDivisionName child elements of ram:PostalTradeAddress and requires the count to be no greater than one.

Where the rule applies

The rule applies to the postal address of the end user's legal organization under ProductEndUserTradeParty.

Context (rule/@context)
/rsm:CrossIndustryInvoice/rsm:SupplyChainTradeTransaction/ram:ApplicableHeaderTradeAgreement/ ram:ProductEndUserTradeParty/ram:SpecifiedLegalOrganization/ram:PostalTradeAddress
Test expression (assert/@test)
count(ram:CountrySubDivisionName)<=1