Introduction
Every Friday, an operations analyst at a B2B distributor exports orders, shipments, invoices, and stock from four systems, merges them in Excel, and highlights problems: orders shipped but not invoiced, invoices without a delivery proof, stock that went negative, and prices below cost. The list goes to managers on Monday, by which time some problems are a week old and others have already been fixed.
The analyst's spreadsheet is valuable. It encodes exactly what the business considers a problem. What it lacks is speed, ownership, and memory: nobody knows which issues were resolved, by whom, or which ones keep coming back.
In this article you will learn how to turn those rules into an exception engine, store exceptions as records with owners and service levels, detect and auto-resolve them continuously, and design a dashboard that drives action.
Turning Rules Into Exception Definitions
Start with the analyst's spreadsheet. Each highlighted condition becomes an exception rule with a name, a severity, an owning team, a target resolution time and a query that returns the records currently in breach.
CREATE TABLE exception_rules (
code text PRIMARY KEY, -- 'SHIPPED_NOT_INVOICED'
description text NOT NULL,
severity text NOT NULL, -- high, medium, low
owner_team text NOT NULL,
sla_hours int NOT NULL,
detect_sql text NOT NULL -- returns entity_type, entity_id, branch_id, details
);
-- example detect_sql for SHIPPED_NOT_INVOICED
SELECT 'shipment', s.id, s.branch_id, jsonb_build_object('order', s.order_id)
FROM shipments s
LEFT JOIN invoices i ON i.order_id = s.order_id
WHERE s.shipped_at < now() - interval '4 hours' AND i.id IS NULL;
Keeping rules as data lets operations leaders review them and lets you add a rule without changing application code. Have an engineer review each query for correctness and performance before it goes live.
Storing Exceptions as Records
Each detected problem becomes an exception record with the rule code, the entity it refers to, when it was first detected, its current status, an assigned owner, and a due time based on the rule's SLA. A unique constraint on the rule and entity ensures the same problem is not raised twice.
The detector runs every few minutes. It upserts records for current breaches, updating last_seen_at, and marks open exceptions as auto-resolved when their entity no longer appears in the rule's results. This auto-resolution is what makes the dashboard trustworthy: fixed problems disappear without anyone remembering to close them.
Detection: Scheduled, Triggered or Streamed
For most B2B operations, a scheduled detector every one to five minutes is enough and is easy to reason about. If certain exceptions need to appear within seconds, such as negative stock at a dispatch counter, trigger detection from the relevant events through your outbox or change data capture. Keep both paths writing to the same exceptions table.
Run detection against a read replica or reporting schema if the queries are heavy, so operational systems are not slowed down.
**Designing a Dashboard That Drives Action
**Show open exceptions grouped by owner team and severity, sorted by time to SLA breach. Each row links to the record in the source system and allows assigning, commenting, snoozing with a reason, or marking as accepted. Show trends per rule over weeks so managers can see which problems are recurring and fix the causes rather than the symptoms.
Send notifications sparingly: a daily digest per owner, plus immediate alerts only for high-severity rules or SLA breaches.
Practical Examples: Real-World Use Cases
The distributor from the introduction converted nine spreadsheet checks into exception rules. Shipped-but-not-invoiced orders, previously found up to a week later, are now flagged within four hours and typically invoiced the same day.
A building materials supplier added a rule for sales below cost price. The weekly trend showed most cases came from one branch with an outdated price list, which was fixed in an afternoon.
A third-party logistics company uses exceptions for shipments with no tracking update in 24 hours. Customer service now calls the carrier before the customer calls them.
Common Mistakes to Avoid
Rebuilding the spreadsheet as a static report instead of a list of owned exceptions.
Requiring people to close exceptions manually when the underlying data is already fixed.
Too many low-value rules, which bury important problems.
Running heavy detection queries against production at peak times.
Exceptions without owners or due times.
Best Practices: Actionable Tips
Start with the five rules that cost the most money or customer trust.
Give every rule an owner team and an SLA before switching it on.
Track time to resolution and recurrence per rule.
Review rules monthly and retire ones that no longer find anything useful.
Link every exception directly to the record that needs fixing.
Conclusion
An exception dashboard replaces the weekly Excel merge with a continuously updated, owned list of problems. Turn spreadsheet checks into rule definitions, store exceptions as records with owners and SLAs, detect and auto-resolve them on a schedule or from events, and design the dashboard around action. The takeaway: report what needs fixing now and who is fixing it, and the business will act on it.
Build Real-Time Operations Reporting With Parallaxis
Parallaxis builds custom operations software for B2B teams, including exception engines and dashboards that connect ERP, CRM, and logistics data. If your team still finds problems by merging spreadsheets, visit parallaxis.in to explore our custom software services or talk to us about your reporting.
Top comments (0)