Element 'ram:RoleCode' may occur at maximum 1 times.
ram:RoleCode occurs more than once in ram:ProductEndUserTradeParty. This element may appear there no more than once.
The XML structure limits the role designation for ProductEndUserTradeParty to a single entry. Multiple entries do not conform to the defined structure.
The invoice contains multiple ram:RoleCode elements for ProductEndUserTradeParty. You can adjust the XML structure so that no more than one entry is present.
- Locate
ram:RoleCodewithinram:ProductEndUserTradeParty. - Remove additional
ram:RoleCodeelements so that no more than one remains. - Generate the invoice again and validate it.
<ram:ProductEndUserTradeParty> <ram:RoleCode>1</ram:RoleCode> <ram:RoleCode>2</ram:RoleCode> </ram:ProductEndUserTradeParty>
<ram:ProductEndUserTradeParty> <ram:RoleCode>1</ram:RoleCode> </ram:ProductEndUserTradeParty>
Technical details
The check verifies that the number of direct ram:RoleCode elements in the rule context is no greater than one.
The rule applies to ram:RoleCode within the header agreement’s ram:ProductEndUserTradeParty element.
rule/@context)assert/@test)