The payee’s address may contain at most one subdivision

Error FX-SCH-A-000916 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 ram:PostalTradeAddress element contains more than one ram:CountrySubDivisionName element.

What the rule means

At most one subdivision value is allowed in the payee party’s postal address; the element may also be absent.

Please use no more than one subdivision in the payee’s address

The payee party’s postal address contains ram:CountrySubDivisionName more than once. It may occur at most once and may also be omitted.

What to do
  1. Find the payee party’s ram:PostalTradeAddress.
  2. Remove any extra ram:CountrySubDivisionName elements so that no more than one remains.
  3. Generate the invoice again and validate it.
What it looks like
✗ Triggers the message
<ram:PostalTradeAddress>
  <ram:CountrySubDivisionName>Subdivision A</ram:CountrySubDivisionName>
  <ram:CountrySubDivisionName>Subdivision B</ram:CountrySubDivisionName>
</ram:PostalTradeAddress>
✓ Correct
<ram:PostalTradeAddress>
  <ram:CountrySubDivisionName>Subdivision A</ram:CountrySubDivisionName>
</ram:PostalTradeAddress>
Technical details

The XPath test checks that there is at most one direct ram:CountrySubDivisionName child of ram:PostalTradeAddress.

Where the rule applies

The rule applies to the payee party’s postal address in the invoice settlement.

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