At most one subdivision in the organization’s address

Error FX-SCH-A-000687 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

The postal address contains ram:CountrySubDivisionName more than once. This element may occur at most once there.

What the rule means

ram:CountrySubDivisionName provides the country subdivision, such as a state or region. Multiple entries at this location do not conform to the permitted address structure.

Please include at most one region in the organization’s address

ram:CountrySubDivisionName occurs more than once in the buyer’s tax representative’s organization postal address. You can resolve this by having this element occur only once there.

What to do
  1. Locate ram:PostalTradeAddress in the buyer’s tax representative’s ram:SpecifiedLegalOrganization.
  2. Keep no more than one ram:CountrySubDivisionName in it.
  3. Generate the invoice again and validate it.
What it looks like
✗ Triggers the message
<ram:PostalTradeAddress>
  <ram:CountrySubDivisionName>Region A</ram:CountrySubDivisionName>
  <ram:CountrySubDivisionName>Region B</ram:CountrySubDivisionName>
</ram:PostalTradeAddress>
✓ Correct
<ram:PostalTradeAddress>
  <ram:CountrySubDivisionName>Region A</ram:CountrySubDivisionName>
</ram:PostalTradeAddress>
Technical details

Within ram:PostalTradeAddress, the number of direct ram:CountrySubDivisionName elements is limited to one.

Where the rule applies

The rule applies to ram:PostalTradeAddress within ram:SpecifiedLegalOrganization for the buyer’s tax representative.

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