L3 โ Complete
Dashboard โ DAX Measures + Live HTML Build
L2's SQL output (99,441 reconciled orders, 6 exception types) needed a visual layer. The DAX measures were built and verified in Power BI Desktop first, then the presentation layer was built directly in HTML for this portfolio โ both are documented below.
๐ Source: l2_exception_classified_dated.csv
๐ Tool: DAX (Power BI) โ Chart.js (HTML)
๐
Completed: Jul 2026
๐ฏ Match rate: 98.37%
L2 produced two files: l2_exception_classified_dated.csv (99,441 order-level rows) and l2_exception_summary.csv (6-row severity rollup). On import, Power BI names each table after its source file โ including the extension โ so the working table name became l2_exception_classified_dated csv, with a space in it. Five measures were built on top of it.
Total Orders โ baseline row count
Total Orders = COUNTROWS('l2_exception_classified_dated csv')
Counts every row in the table, exceptions and matches together. This is the denominator every other rate is measured against โ expected to equal L0's 99,441.
Matched Orders โ filtered count
Matched Orders =
CALCULATE(
COUNTROWS('l2_exception_classified_dated csv'),
'l2_exception_classified_dated csv'[exception_type] = "OK"
)
CALCULATE re-evaluates COUNTROWS under a filter โ here, only rows where exception_type = "OK". This is the count of orders that reconciled cleanly with no exception raised.
Match Rate % โ the headline metric
Match Rate % =
DIVIDE([Matched Orders], [Total Orders])
DIVIDE is used instead of / because it returns blank instead of an error if Total Orders is ever zero. Must be formatted as Percentage in the measure's Format field, or it displays as 0.98 instead of 98%.
Exception Orders โ derived from the two measures above
Exception Orders =
[Total Orders] - [Matched Orders]
Simple subtraction between two already-defined measures โ DAX measures can reference each other, so this doesn't need its own CALCULATE.
Total Financial Exposure โ conditional aggregation
Total Financial Exposure =
SUMX(
FILTER('l2_exception_classified_dated csv', 'l2_exception_classified_dated csv'[exception_type] <> "OK"),
IF(
'l2_exception_classified_dated csv'[exception_type] = "CANCELED_WITH_PAYMENT",
'l2_exception_classified_dated csv'[payment_total],
ABS('l2_exception_classified_dated csv'[diff])
)
)
SUMX walks row-by-row through every exception (everything not "OK") and applies an IF to pick the right number per row. For most exception types, exposure is ABS(diff) โ the reconciliation gap. CANCELED_WITH_PAYMENT is the one case where diff doesn't apply โ there's no order total left to reconcile against โ so exposure there is the full payment_total instead: money collected with no matching delivery.
High Severity Orders โ reusing a measure inside CALCULATE
High Severity Orders =
CALCULATE(
[Exception Orders],
'l2_exception_classified_dated csv'[exception_type] = "CANCELED_WITH_PAYMENT"
)
Same CALCULATE pattern as Matched Orders, but filtering to the single highest-severity exception type and reusing the Exception Orders measure instead of writing COUNTROWS again.
โ Table names with spaces need quotes
Every reference to the table above is wrapped in single quotes: 'l2_exception_classified_dated csv'. Typing the name bare โ l2_exception_classified_dated csv[exception_type] โ throws Failed to resolve name 'l2_exception_classified_dated', because DAX reads the space as the end of the identifier. Any table or column name containing a space, or starting with a number, needs single quotes around it. Using Power BI's autocomplete when typing formulas avoids this โ it inserts the quoted name automatically.
| measure | value | verified against |
| Total Orders | 99,441 | L0 row count |
| Match Rate % | 98.37% | L2 target โฅ95% |
| Exception Orders | 1,618 | L2 exception_summary sum |
| Total Financial Exposure | R$271,891.01 | L2 exception_summary sum |
| High Severity Orders | 622 | CANCELED_WITH_PAYMENT count |