Practice — Medium · Wiring the Targets
Skills focus. Conformed dimensions, the targets join, attainment — and one
deliberately planted bug you will build, watch fail, and fix.
Ungraded. Continue from Mild's model.
Part 1 — The join
- Build
Regions = DISTINCT ( Stores[Region] )andCategories = DISTINCT ( Products[Category] ); relate each to its two homes (Regions → stores and targets; Categories → products and targets). Checkpoint: 6 and 5 rows. - Load
targets.csv; relateTargetMonth→Dates[Date]. Checkpoint: 1,080 rows, and the model diagram now has no islands. - Measures:
Target Revenue = SUM ( Targets[RevenueTarget] )andAttainment % = DIVIDE ( [Total Revenue], [Target Revenue] ). With Year = 2026: Checkpoint: 107.39% overall. - Bar: Attainment % by Category (from the Categories dimension), 2026. Checkpoint: Kitchen & Dining leads at 109.1%; Decor trails at 103.8%; every bar above 100%.
Part 2 — The planted bug
- Create a second measure, exactly as written:
% of Total BROKEN = DIVIDE ( [Total Revenue], CALCULATE ( [Total Revenue], ALL ( Sales ) ) )— note: ALL over the whole fact. - Put it and your correct
% of Total Revenueside by side in the category table, with the Year slicer set to 2025. Describe what differs, and why the broken column's numbers are so much smaller. - Delete the broken measure. (It was built to be seen failing, not to survive.)
Reflection
- Part 1's category attainment ordering (K&D best, Decor worst) differs from every ranking you have seen — revenue, units, margin, and now attainment each crown someone else. What single sentence explains why rankings keep disagreeing?
- The broken measure divided by all-time revenue while the visual showed 2025. Which earlier lesson's mistake is this the CALCULATE-flavored version of?