BR-DE-30
XRechnung 2.5.0 · UBL
Original rule text
[BR-DE-30] Wenn "DIRECT DEBIT" BG-19 vorhanden ist, dann muss "Bank assigned creditor identifier" BT-90 übermittelt werden.
not(cac:PaymentMeans/cac:PaymentMandate) or (cac:AccountingSupplierParty/cac:Party/cac:PartyIdentification/cbc:ID[@schemeID='SEPA'] | cac:PayeeParty/cac:PartyIdentification/cbc:ID[@schemeID='SEPA'])What this rule requires
The rule [BR-DE-30] requires that when direct debit information (BG-19) is present, the bank assigned creditor identifier (BT-90) must also be provided. In UBL, the document passes if there is no cac:PaymentMeans/cac:PaymentMandate, or if that element is present and a SEPA identifier exists in either cac:AccountingSupplierParty/cac:Party/cac:PartyIdentification/cbc:ID[@schemeID='SEPA'] or cac:PayeeParty/cac:PartyIdentification/cbc:ID[@schemeID='SEPA']. In CII, the document passes if none of DirectDebitMandateID, CreditorReferenceID, or IBANID exists, or if CreditorReferenceID exists together with at least one of DirectDebitMandateID or IBANID. A fatal rule, so an invoice failing any of these conditions is rejected.
How to fix
In UBL, if cac:PaymentMeans/cac:PaymentMandate is present, add a cac:PartyIdentification/cbc:ID with @schemeID='SEPA' containing the creditor identifier to either the supplier or payee party. In CII, ensure ram:CreditorReferenceID is supplied when ram:DirectDebitMandateID or ram:IBANID is present, and do not supply ram:CreditorReferenceID alone without at least one of those. If no direct debit is used, omit these elements.
Guidance on this rule. The original text above is authoritative.