Back to Roadmap
Level 6 — Advanced DAX Mastery+80 XP
Lesson 1
1. Context Transition
How CALCULATE turns row context into an equivalent filter context.
The Concept
When CALCULATE is invoked within a row context, it transforms all column values of the active row into an equivalent filter context.
Example DAX:
// Inside SUMX or calculated column:
// Calling a measure implicitly wraps it in CALCULATE, triggering Context Transition!
Avg Sales Per Cust =
AVERAGEX(
Customers,
[Total Revenue] // [Total Revenue] is evaluated as CALCULATE([Total Revenue])!
)Understanding context transition is the defining milestone that separates junior Power BI developers from senior DAX architects.
Try It Yourself
Create a measure 'Max Customer Spend' calculating MAXX over Customers with [Total Revenue].
fx
[fx]Context Transition=
Loading DAX Formula Studio...
Type [ for fields