Element 'ram:CountryID' must occur exactly 1 times.
The element ram:PostalTradeAddress does not contain exactly one ram:CountryID. It is either missing or occurs more than once.
ram:CountryID specifies the country of the delivery address. The postal address must contain exactly one such country value.
The delivery recipient’s postal address does not contain exactly one ram:CountryID. You can adjust the country value in the address.
- Locate
ram:CountryIDunderram:PostalTradeAddressofram:ShipToTradeParty. - Make sure exactly one
ram:CountryIDis present. - Generate the invoice again and validate it once more.
<ram:PostalTradeAddress/>
<ram:PostalTradeAddress> <ram:CountryID>DE</ram:CountryID> </ram:PostalTradeAddress>
Technical details
The XPath condition checks whether the number of child elements named ram:CountryID is exactly one.
The rule applies to the postal address of the delivery recipient under ShipToTradeParty for an invoice line.
rule/@context)assert/@test)