Add measures to Power BI Desktop models Flashcards
What are implicit measures in Power BI?
Automatic behaviors that allow visuals to summarize model column data without explicitly defining calculations.
How are numeric columns identified in the Fields pane in Power BI?
By the sigma symbol (∑), indicating they are summarizable.
What is the default summarization for a numeric column in Power BI?
Sum, but it can be changed to average, minimum, maximum, count (distinct), count, standard deviation, variance, or median.
How are text columns summarized in Power BI?
With first (alphabetically), last (alphabetically), count (distinct), and count.
What are the limitations of implicit measures?
They can be aggregated inappropriately, only work for simple scenarios, and are not supported by MDX queries.
How do you add a measure to a table in Power BI?
Select the table in the Fields pane, then go to the Table Tools contextual ribbon, and select New measure.
What is the DAX formula to create a Revenue measure?
Revenue = SUM(Sales[Sales Amount])
How do you format a measure in Power BI?
After creating the measure, use the Measure tools contextual ribbon to set formatting options like decimal places.
What are some examples of simple measures using different DAX functions?
Minimum Price = MIN(Sales[Unit Price])
Maximum Price = MAX(Sales[Unit Price])
Average Price = AVERAGE(Sales[Unit Price])
How do you create a measure that counts rows in a table?
Use the COUNTROWS function, e.g., Order Line Count = COUNTROWS(Sales)
Why is it recommended to hide columns after creating measures?
To limit summarization options and ensure report authors use the defined measures.
What is a compound measure in Power BI?
A measure that references one or more other measures.
How do you define a Profit measure in DAX?
Profit = [Revenue] - [Cost]
What is the benefit of using compound measures over calculated columns?
They optimize the semantic model by reducing its size and shortening data refresh times.
What should be done with calculated columns when a compound measure can produce the required result?
Remove the calculated columns to optimize the model.
What is the Quick Measures feature in Power BI?
A feature that allows you to quickly perform common calculations by generating the DAX expression for you.
How do you create a quick measure for profit margin in Power BI?
Select the Sales table, go to Table tools > Quick measure, choose Division, and configure the measure with Profit as the numerator and Revenue as the denominator.
What DAX formula is generated for the quick measure to calculate profit margin?
Profit divided by Revenue = DIVIDE([Profit], [Revenue])
How do you format the Profit Margin measure in Power BI?
Rename it as Profit Margin, and set the format to a percentage with two decimal places.
What is the main difference between calculated columns and measures in Power BI?
Calculated columns are computed during data refresh and stored in the model, while measures are calculated at query time.
When should you use calculated columns?
Use calculated columns when you need to filter or group data by the column or use it in relationships.
When should you use measures?
Use measures for calculations that need to be dynamic and context-aware, such as aggregations.
What is a potential downside of using calculated columns?
They can increase the size of the model and affect performance.
What is an advantage of using measures over calculated columns?
Measures are more efficient as they do not increase the model size and provide flexibility in dynamic calculations.