Forum Discussion
veshva40
10 months agoRegular Visitor
Help with Divide Function (total percentage)
Hi everyone, I’m having some trouble calculating percentages in Power BI. As you can see in the image below, I want it to show the percentage of completion for each batch separately. But right now, t...
- 10 months ago
It looks like a syntax error in your SUM(). It's missing a bracket after 'Table1'[TOTAL].
Try this instead.Total% =
DIVIDE(
'Table1'[TOTAL],
CALCULATE(
SUM('Table1'[TOTAL]),
ALLEXCEPT('Table1', 'Table1'[Batch])
)
)
veshva40
10 months agoRegular Visitor
Thank you for your advice. Based on your reply, I tried below computation but it throws me error 'too many arguments were passed to the SUM function. The maximum argument count for this function is 1.
Total% = DIVIDE('Table1'[TOTAL],CALCULATE(SUM(Table1[TOTAL],ALLEXCEPT(Table1,Table1[Batch]))))
- MasonMA10 months ago
Super User
It looks like a syntax error in your SUM(). It's missing a bracket after 'Table1'[TOTAL].
Try this instead.Total% =
DIVIDE(
'Table1'[TOTAL],
CALCULATE(
SUM('Table1'[TOTAL]),
ALLEXCEPT('Table1', 'Table1'[Batch])
)
)