Academy index

Page referenceAdvanced/purchases/three-way-matching

Three-Way Matching

This page compares a supplier bill's total with its purchase order's total. The main fields and buttons, what it really computes, and what does not work.

Reviewed independently, claim by claim against the sources and the screens, on 4 December 2026.

Last checked against the screen and the code: 4 December 2026, version 080e20835.

This page of the program is under construction: the reference states only what works in it today.

What this page is

Despite its name, this page does not match goods receipts: its figures and statuses compare the bill's total with the order's total only. The real match of order, receipt and bill runs when the bill is approved, on the supplier bills page or with «Approve» here, which is the same approval, and reads none of this page's statuses or figures; it reads only the bill's link to the order, which this page writes (see below).

Each «matching session» is a supplier bill that is not cancelled and is linked to a purchase order, whatever its status, and the page shows the latest 200. The variance = the bill's total minus the order's total, and the percentage = the variance ÷ the order's total × 100, both totals with VAT. The status follows the percentage: up to 0.01% «Perfect match», up to 2% «Within tolerance», up to 10% «Variance», above it «Blocked». The receipt column shows the order's latest receipt for information only and takes no part in the computation. So a correct bill for a partial receipt shows «Blocked», being well below the order's total, and «Approve» still shows for it.

Linking a bill to an order

«New Match» links a draft supplier bill to a purchase order. The link changes what happens when the bill is approved later: its goods lines are then accepted only for what was received on the order and not billed yet, their price is checked against the order's, and the order must be approved. The server refuses linking a bill that is not a draft, a bill of another supplier than the order's, or an order that already has any other bill linked to it, even a cancelled one; on the Arabic screen these refusals come as short general Arabic sentences that name neither the linked bill's number nor its status (the English screen keeps the server's English reasons). «Auto Match» links each unlinked draft bill to the closest open order of the same supplier that has no bill linked, when the two totals differ by 2% or less.

The «Approve» button

It is the bill's own approval, the same as «Approve Bill» on the supplier bills page: it checks that the bill's goods were received and not invoiced yet, matches its lines with the order at the company's tolerance, goes through the approval workflow if the company has an active one, then posts its entry (the debt to the supplier, the input VAT, the clearing of goods received not invoiced), and the bill becomes «Pending» on the supplier bills page. It needs the payables approval right, that is approval in purchases or in accounting, which the server's own guard on this door checks. The user who created the bill cannot approve it while another active member of the company holds the right to approve it; if no one else holds it, the window «Approve your own document?» asks them for the reason. The button shows on every session whose bill is not posted yet, «Blocked» ones too, because the approval's own match decides, not this page's statuses. If that match blocks the bill, the refusal shows its deviations, and this page cannot release the block because it sends no reason: release it on the supplier bills page, which asks for the release reason. If the bill reaches the approval workflow's threshold, it is sent to the approver and stays a draft, and this page shows that as an error message naming to whom it went. A cancelled bill or one already posted is refused with its status.

What does not work today

  • The match does not read the receipts: it compares the two totals only, and the «receipt amount» the server sends is the order's own total. The page description promises to match orders, receipts and bills.
  • Clicking a session row loads the line comparison and never shows it: a loading sign appears, then the page comes back as it was.
  • The «Goods Receipt» chosen in the «New Match» window is not used; the server ignores it.
  • Amounts are shown in the company's currency whatever the order's and bill's currency, the percentage is computed without conversion, and the «Total Variance» card adds the variances of every session in their different currencies.
  • The pending bills list holds every draft bill, linked ones too, so the «Pending Review» card counts them twice. The orders list includes draft and unapproved orders, and the receipts list includes reversed ones. Each card of the «Pending Documents» tab shows its first five only.
  • «Auto Match» ignores the order's approval and currency, and links to another supplier's order when either document has no supplier.
  • An order whose linked bill was cancelled still counts as taken by it: «Create Match» refuses to link it to another bill and «Auto Match» skips it, although the cancelled bill no longer shows among the sessions.
  • The search looks at the supplier's name only. If you change it while on a page other than the first, the list does not go back to page one.

Before you start

  • Purchase orders and draft supplier bills of the same supplier.

Fields

Field as on the screenMeaningRequired
Purchase OrderThe order the bill is linked to, from the latest 50 orders that are not cancelled or closed.Yes
Goods ReceiptShown as optional, but the server does not use it.No
Select InvoiceThe draft supplier bill linked to the order.Yes
Search...Searches the sessions by supplier name.No

Buttons and actions

ButtonWhen it showsWhat it doesPosts
New MatchAt the top of the page.Opens the window that links a bill to an order.No
Create MatchIn the window, once the order and the bill are chosen.Links the draft bill to the order, and a new session shows. It posts nothing.No
Auto MatchAt the top of the page.Links unlinked draft bills to orders whose totals differ by 2% or less, and says how many were linked and how many were left. It posts nothing.No
ApproveOn each session row whose bill is not posted yet, «Blocked» ones too.Approves and posts the bill, as «Approve Bill» does on the supplier bills page (see above), or sends it to the approval workflow and it stays a draft.Yes
ExportAt the top of the page.Downloads the sessions table shown as a CSV file, the rows of the page shown only.No

The document's statuses

  • Perfect match: The totals differ by 0.01% or less.
  • Within tolerance: The difference is above 0.01% and up to 2%.
  • Variance: The difference is above 2% and up to 10%.
  • Blocked: The difference is above 10%. Despite its name it blocks nothing: «Approve» still shows, and the approval's own match decides.
  • Approved: The bill was posted (it has an entry) or is paid.

The journal entry

At «Approve»: the same entry «Approve Bill» posts

10 units at AED 100 received on the order, billed at 1,000 with VAT 50
AccountDebitCredit
Dr Goods received not invoiced1,000
Dr Input VAT50
Cr Accounts payable (the supplier)1,050
Total (AED)1,0501,050

Permissions

ToPermission needed
Open the page and read the sessions and pending documentsPurchases — View
«Create Match» and «Auto Match» (linking bills to orders)Purchases — Create

Refusals and fixes

  • BILL_BEFORE_RECEIPT

    Nothing of the order's goods has been received yet, so its bill is not approved.

    Fix: Post the goods receipt on the Goods receipts page, then press «Approve» again.

  • BILL_QTY_ABOVE_RECEIPT

    A goods quantity on the bill is more than was received and not invoiced; the message gives what is allowed.

    Fix: Correct the bill on the supplier bills page to bill only what was received, or post the rest of the receipt first.

  • APPROVAL_REQUIRED

    Not a refusal, although this page shows it as an error: the bill reached the approval workflow's threshold, so it was sent to the approver and stays a draft. The message says to whom.

    Fix: Wait for the approval on the Approvals page; the bill is posted then.

  • SOD_VIOLATION

    You created the bill, and another active member of the company holds the right to approve it.

    Fix: Have that user approve it.

  • SELF_APPROVAL_REASON_REQUIRED

    You created the bill and no one else in the company holds the right to approve it: the window «Approve your own document?» asks for the reason, and if you close it this refusal shows.

    Fix: Type the reason (at least 5 characters) and press «Approve with this reason»; it is kept in the audit trail as a self-approval. Or give another user the approval right to approve it.

  • ALREADY_APPROVED

    The bill was already posted, for example on the supplier bills page after this list was read; the message gives its status.

    Fix: Refresh the page; nothing else is needed.

  • BILL_CANCELLED

    The bill was cancelled after this list was read, and a cancelled bill is never approved.

    Fix: Refresh the page; the session leaves it.

Learn the idea

Educational content for general understanding, not accounting, tax or legal advice. Sources · About the Academy