UBL-SR-47: When there are more than one payment means code, they…

When there are more than one payment means code, they shall be equal

The message validators print

UBL-SR-47 is a rule of the UBL syntax rules (UBL-CR, UBL-SR, UBL-DT) (CEN validation artefacts 1.3.16) for UBL. It is an error (fatal): a validator rejects the invoice. This rule has no explanation of its own yet; the page is not indexed until it has one.

UBL
[UBL-SR-47]-When there are more than one payment means code, they shall be equal

The rule as published

Where the rule applies (context) and what must hold (test), unmodified from CEN EN 16931 validation artefacts 1.3.16. An assert fails when its test is false.

Text and test: © CEN/TC 434, EN 16931 validation artefacts, EUPL 1.2. Quoted unmodified; the explanations on this page are Veriport’s.

UBL · CEN EN 16931 validation artefacts (UBL) 1.3.16 · assert · error
context: /ubl:Invoice | /cn:CreditNote
test:    count(//cbc:PaymentMeansCode[not(preceding::cbc:PaymentMeansCode/. = .)]) <= 1

Check your own invoice

Drop your XRechnung, ZUGFeRD or Peppol file into a free validator (Peppol BIS, XRechnung, Factur-X): each runs the same rule files and links every finding to its rule page. From your own code, POST /einvoice/validate (reference) returns the same check as JSON, each finding with an explanation field pointing here (5 calls a check, anonymous within the daily allowance).

Sources