Three documents that should say the same thing
Every purchase you make leaves three traces. The order you sent the supplier, the delivery note that came in on the truck, and the invoice that asks you for the money
In practice they almost never match line by line. The three-way match is exactly that, putting the three pieces of paper side by side to work out whether you're paying for what you asked for and for what you actually got
You ordered a hundred pieces, ninety-eight turned up because two were broken or out of stock, and the invoice charges you for a hundred. The numbers are invented here to show the mechanism, they aren't anybody's real case
The gap is two pieces, and on a single line nobody notices it. But there's never just one line
Why almost nobody does this check by hand
The three-way match isn't difficult, it's long, and that difference matters
To check a long invoice, say forty lines, you have to pull out the order, then pull out the delivery notes attached to it, and there can be more than one because the goods arrived over several trips. Then you compare code by code, quantity by quantity, price by price
It isn't a two-minute job, and you don't get one supplier invoice a month. So you can do the sum yourself, that time doesn't exist in the office
What actually happens is that someone looks at the total, sees it's more or less what they expected, and records it. Then you pay, and the supplier collects on the two pieces he never delivered
That isn't carelessness, it's the arithmetic of the time available. It's also why this job is one of the best candidates for automation: high repetition, clear rules, and a machine that is as attentive on line forty as it was on line one
How the comparison is built, step by step
The first step is having the three documents in a readable form, and that's usually easier than it sounds. The order is already inside the business software you use, the delivery note arrives on paper or as a PDF, and the invoice today almost always arrives as an e-invoice, which is the cleanest of the three sources
The second step is the matching, working out which invoice belongs to which delivery note and which delivery note to which order. Here you use the references the documents already carry, the order number quoted on the delivery note, the delivery note number quoted on the invoice
When the reference is missing, and it happens, you match on what you do have, the supplier, the period, the item codes. If the match stays uncertain the system doesn't guess, it sets the line aside
The third step is translating the codes, because the supplier calls the item one thing and you call it another. Without a table that lines them up the comparison can't even start
The fourth step is the comparison itself, line by line, on the three things that count. Quantity ordered against quantity delivered against quantity invoiced, invoice price against the price agreed in the order, and the discounts or surcharges that sometimes show up only at the bottom
What happens to the differences
This is where you see the difference between a useful automation and a toy. The system doesn't decide who's right between you and the supplier, because that judgement is yours. Maybe you accepted the two missing pieces over the phone and nobody ever wrote it down
What the system does is prepare the list of differences with the three documents side by side, line by line, showing what you ordered, what arrived, what you're being charged for, and how far apart they are
The lines that come out perfect go through and nobody looks at them, which is right. The lines that don't stop and wait for a person
It's also worth setting a threshold of your own, below which a tiny difference isn't worth the phone call. A list that flags everything soon stops being read, and a list nobody reads is the same as not having one
Where to start if you want to try it
Take the supplier invoices from one month only, and from one supplier only, the one you buy from most often, and do the check by hand on those
What you find tells you two things. Whether the problem really exists in your company, and which awkward cases you'll have to explain to whoever writes the rules, the partial delivery, the return, the code that changed halfway through the year
It's worth doing even if you never build the automation, because if no money of yours is leaking out of those lines you've found out that in your company this problem isn't there
If you decide to go ahead, the rest is the usual craft. The data is read from the programs you already use, including the ones with no direct integration at all, and the logic is the same as reconciling two sources that don't agree, only with one source more
