Forum Discussion
shaykoooo
Helper I
8 years agoDifferenr results then expected
Hi, In sheet "???", I have two measres, Average Quantity Sold per Day = AVERAGEX(VALUES(Dates[Date]),[Total Quantity Sold]) and Average Quantity Sold per Day 2 = AVERAGEX(VALUES(Dates[Date]),SUM(Sal...
- 8 years ago
You should wrap the sum inside calculate to transform the ROW context into FILTER CONTEXT
Average Quantity Sold per Day 2 = AVERAGEX ( VALUES ( Dates[Date] ), CALCULATE ( SUM ( Sales[Quantity] ) ) )
Zubair_Muhammad
Community Champion
8 years ago
You should wrap the sum inside calculate to transform the ROW context into FILTER CONTEXT
Average Quantity Sold per Day 2 = AVERAGEX ( VALUES ( Dates[Date] ), CALCULATE ( SUM ( Sales[Quantity] ) ) )
shaykoooo
Helper I
8 years agoAnd in the first measure there is no need to wrap the measure [Total Quantity Sold] there is no need to with CALCULATE since measures have an Implicit CALCULATE?