Forum Discussion

JGG's avatar
JGG
Helper I
5 years ago
Solved

Fixed Measure

Hi, I have some overhead cost on monthly basis that should be equaly distributed per customer based on the number of customers for each period. My measure looks good, but it fails used in a table vi...
  • v-jingzhang's avatar
    5 years ago

    JGG , change your measure like below then you will get the result you want.

    CostAllPerCustomer = CALCULATE(SUM(CostTable[Cost]),CostTable[Type] IN {"All"})/CALCULATE(DISTINCTCOUNT(CustomerTable[CustomerId]),ALLEXCEPT(CustomerTable,CustomerTable[Period]))

    Best Regards,

    Community Support Team _ Jing Zhang

    If this post helps, please consider Accept it as the solution to help other members find it.