Don't miss your chance to take exam DP-600 or DP-700 on us!
Request nowLearn from the best! Meet the four finalists headed to the FINALS of the Power BI Dataviz World Championships! Register now
I need to calculate a new measure which allows me to calculate the weight to each country excluding the cash weight. In the example above the country allocation is 95.73% and there is therefore 4.27% cash in the portfolio. I need to divide each country weight by 0.9753 so that the country weight sums to 100%. How can I write a new measure to calculate that?
Solved! Go to Solution.
Superb! I'm never going to admit how long that took!!! I now have to understand the use of divide in your example why not use / ?
Try this pattern
Total=calculate(sum(table[weight]),all(table[country]))
new percent = divide(sum(table[weight]),[Total])
Superb! I'm never going to admit how long that took!!! I now have to understand the use of divide in your example why not use / ?
Divide has an auto "divide by zero error" protection built in. I just use it routinely rather than / even if there is no chance of div 0 errors.
Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.
Check out the February 2026 Power BI update to learn about new features.
| User | Count |
|---|---|
| 50 | |
| 40 | |
| 37 | |
| 14 | |
| 14 |
| User | Count |
|---|---|
| 85 | |
| 69 | |
| 37 | |
| 29 | |
| 27 |