BR-CO-10-SG

Sum of Invoice line net amount (BT-106) = Σ Invoice line net amount (BT-131).

error: the document is invalid

What the rule checks

As the rule set's publisher wrote it. The rule runs on every element the context matches, and fails where the test is false; the validator reports the line of that element.

Context
cac:LegalMonetaryTotal
Test
(round(xs:decimal(cbc:LineExtensionAmount) * 10 * 10) div 100 = (round(sum(//(cac:InvoiceLine|cac:CreditNoteLine)/xs:decimal(cbc:LineExtensionAmount)) * 10 * 10) div 100))

Checked with PINT SG Invoice, PINT SG Credit Note