UBL Order line total mismatch: quantity, price and base units
Find and repair rounded line arithmetic errors before order import. The report includes ORDER-LINE-TOTAL, a source line and XML path.
What the mismatch means
An ERP can export well-formed XML while the amount on an order line disagrees with its quantity and price. Our independently written partial preflight compares LineExtensionAmount with Quantity multiplied by PriceAmount, divided by BaseQuantity, then adjusted by line charges and allowances. A missing BaseQuantity means a price per one ordered unit. A supplied base must be positive and must use the same unit as the ordered quantity. The check does not invent a unit conversion.
The fictional example orders two units at EUR 12.50 each and declares EUR 25.01 on the line. At the explicitly selected two-decimal precision, this produces ORDER-LINE-TOTAL at line 17. The corrected line amount is EUR 25.00. This fixes this arithmetic difference only; the buyer still needs the correct product, price agreement and delivery conditions.
Account for adjustments and rounding
The computation uses decimal integers with up to six fractional places, avoiding binary floating-point comparisons. A line charge increases the expected net amount; a line allowance reduces it. The result is rounded once at the selected precision, using nearest rounding with halves away from zero. Choose the agreed zero-, two- or three-decimal convention. The tool does not bundle a currency code list and cannot choose your profile’s precision for you.
Header allowances and charges belong to document-level monetary totals; they are not distributed silently over individual lines. Document line totals compare the reported top-level line amounts. Tax-exclusive totals include header adjustments. Tax-inclusive comparisons require a single comparable TaxTotal and explicit operands; payable compares the supplied inclusive total, prepaid amount and rounding amount. Missing optional operands leave a named check unexecuted. Sublines and different base units prevent comparisons that would otherwise give a misleading result.
Before and after
Before: independent check fails
2 × 12.50 / 1 → LineExtensionAmount 25.01After: this mismatch is resolved
2 × 12.50 / 1 = 25.00Download the fictional error · Passing independent-rule sample · Known outcomes and locations.
Repair and verify each layer
- Confirm the receiver’s intended UBL version and purchasing process in your ERP configuration.
- Use the XML location to correct the generator rather than repeatedly editing exported files.
- Run the independent preflight again and inspect skipped conditions. A partial passing result is not a full profile approval.
- For schema validation, add a complete authorised local XSD package with concrete per-artifact rights and provenance. Without it, XSD remains not executed.
Free checks one document. Pro and Team batch checks retain existing limits and isolate a broken file. User-initiated CSV and JSON reports preserve selected profile, versions, rounding precision, layer status and schema hashes. XML content is not sent to analytics or an external validator.
Primary sources and scope
OASIS UBL 2.1 and the official Order XSD define the shared structural basis. Peppol Order only 3.3 and Peppol Ordering 3.3 describe different processes and additional constraints. Sources were rechecked on 6 November 2026; the checks and fictional examples here were independently written. No official Schematron text or rule implementation is copied.
OASIS copying and implementation assistance require notices and unchanged original schemas. The complete XSD import chain also includes separately published components; ETSI artifact rights remain unresolved for distribution here, so no full official package is bundled. The BIS document redistribution restriction is not assumed to apply to every repository artifact, but individual official rule rights were not established. BYO and local processing do not remove restrictions. The optional local adapter only supports self-contained XPath 1.0 assertions; unsupported official packages stay unexecuted.
This guide establishes no Peppol certification, access point, network delivery, complete BIS validity, party registration, commercial correctness or national order mandate. Generic UBL checks do not require Peppol membership. A future network integration requires a separate decision.
Recheck your regenerated order
UBL Order validator · Related UBL Order repair guide · API / CLI scope