These are generally better candidates for measures, because they need to respond dynamically to report filters.
🎯 Power BI Interview Questions
•
What is DAX? DAX is the formula language used in Power BI for analytical calculations.
•
What is the difference between a calculated column and a measure? A calculated column calculates values row by row and stores them in the model. A measure calculates dynamically based on the current filter context.
•
What is filter context? The set of filters affecting a DAX calculation.
•
What is row context? The current row being evaluated, particularly relevant to calculated columns and certain DAX iterators.
•
What does CALCULATE() do? It evaluates an expression after modifying the filter context.
•
Why use DIVIDE()? It provides safer division handling, especially when the denominator can be zero or blank.
🎯 Practice Task
Create these measures in a sample Sales model:
• Total Sales = SUM(Sales[Sales_Amount])
• Total Cost = SUM(Sales[Cost])
• Total Profit = [Total Sales] - [Total Cost]
• Profit Margin = DIVIDE([Total Profit], [Total Sales])
Then create Cards for each measure. Add a Region slicer. Change the region and observe what happens. This is one of the easiest ways to understand filter context practically.
💡 The biggest DAX concept to understand at this stage is: A measure doesn't simply calculate a number. It calculates a number based on the current context of your report.
Power BI Resources: https://whatsapp.com/channel/0029Vai1xKf1dAvuk6s1v22c
Double Tap ❤️ For Part-5
Post #3127
2.81K
- ❤ 5