Element 'ram:CategoryCode' must occur exactly 1 times.
ram:CategoryCode is missing from ram:AppliedTradeTax, or the element occurs more than once.
ram:CategoryCode assigns the tax information to a tax category. Exactly one element ensures that the category is stated unambiguously.
The tax information for the logistics service is missing the tax category, or it includes it more than once. A single entry makes the category clear.
- Find the relevant
ram:AppliedTradeTax. - Add exactly one
ram:CategoryCodeinside it and remove any duplicates. - Generate the invoice again and validate it again.
<ram:AppliedTradeTax/>
<ram:AppliedTradeTax> <ram:CategoryCode>S</ram:CategoryCode> </ram:AppliedTradeTax>
Technical details
The test uses count(ram:CategoryCode)=1 to check that ram:AppliedTradeTax contains exactly one ram:CategoryCode element.
The rule applies inside ram:AppliedTradeTax, which belongs to the tax information for a logistics service.
rule/@context)assert/@test)