Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
6 years ago
Solved

managed aggregation with direct query table - using measures and average values - not possible?

Hi,  I am not seeng the option for using average in managed aggregations.  e.g. see screenshot below Also can we use measures in managed aggregations?  the answers seems no.  , you can not se...
  • Anonymous's avatar
    Anonymous
    6 years ago

    Got the answers I need!!!
    There is an amazing article (2019/11) by Shabnam Watson that provided me with the answers:
    https://shabnamwatson.wordpress.com/2019/11/21/aggregations-in-power-bi/

    To get an average value, create a measure against the details table where the masure can be broken down to the basic calculation of sum/count  - this measure will hit the manged aggregation table that is in memory when placed into a visual.  Note, creating a measure using the divide() with sum and count calculation against the details table works but a measure created with the average() will not work
    e.g.  

    avg pricepaid = DIVIDE(sum(ProperyDetails[PricePaid]) , COUNTROWS(ProperyDetails) )  - works and hits the aggrgated table
    avg pricepaid 2 = AVERAGE(ProperyDetails[PricePaid])   - does not hit the aggegated table.