How to extract a credit note without reversing the sign twice
3 November 2026
Store the credit note’s printed amount exactly as it appears, including any minus sign or brackets. Keep the document type in a second field. Only then derive the amount needed for the particular reconciliation. If one system makes the amount negative and the next system subtracts it again, the credit increases the total instead of reducing it.
Follow an unsigned credit through the calculation
The synthetic record SYN-CN-003 is labelled as a credit note and shows a USD total of 20.00, with no minus sign. The same fixture includes SYN-INV-001, a USD invoice for 137.50 from the same fictional supplier. The separate EUR invoice is outside this USD calculation. Ground truth · Test results
| Field | Invoice | Credit note |
|---|---|---|
| Document type | Invoice | Credit note |
| Printed total | USD 137.50 | USD 20.00 |
| Contribution to this reconciliation | +137.50 | −20.00 |
Add the two directional amounts and the result is 117.50 USD. The local test records that total for the USD documents. Now try the deliberate error: an intake step has already given the credit a directional value of −20.00, but a later step subtracts it again. 137.50 − (−20.00) = 157.50. That is 40.00 above the intended 117.50, twice the size of the original credit. This second calculation illustrates the fault; the test did not post an erroneous transaction. Test results
Keep the source amount recoverable
For each document, retain the input identifier, source location, printed type, printed amount, currency, intended direction, sign rule used and destination field. Give the destination a clear contract: does it receive a signed adjustment to add, or an unsigned amount and a document type telling it what to subtract? Pick one interpretation for that interface and test it with the figures above.
A harder case is a document labelled as a credit that already prints −20.00. Preserve both the label and the visible sign. Do not apply the previous unsigned-input rule automatically. Have the reviewer check the source, the agreed interpretation for that document format and the destination’s expectation. Record the reason for the chosen contribution or leave the sign unresolved.
A passing total is evidence about this arithmetic. It does not authenticate a supplier or authorise payment. Before releasing an import, ask a second reviewer to reproduce the same signed contribution from the source fields and confirm the result in the destination’s own preview or reconciliation report. Test results
Part of the Five checks for data extracted from a PDF invoice guide.
Published by Arke Technologies (Pty) Ltd, Johannesburg. Drafted with NotebookLM. Source checks and editing by Kairos (Codex).
