Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more
Hello,
I would like to know how to calculate the ratio of each row divided by the sum of the same rows within a group using calculated column.
Regards,
| projectskey | fiscalPeriod | Forecast Distribution | Sum of Forecast Distribution | Factor |
| 1299647 | 202001 | 0.01 | 1.23 | 0.00813 |
| 1299647 | 202002 | 0.04 | 1.23 | 0.03252 |
| 1299647 | 202003 | 0.08 | 1.23 | 0.065041 |
| 1299647 | 202004 | 0.15 | 1.23 | 0.121951 |
| 1299647 | 202005 | 0.22 | 1.23 | 0.178862 |
| 1299647 | 202006 | 0.22 | 1.23 | 0.178862 |
| 1299647 | 202007 | 0.22 | 1.23 | 0.178862 |
| 1299647 | 202008 | 0.15 | 1.23 | 0.121951 |
| 1299647 | 202009 | 0.08 | 1.23 | 0.065041 |
| 1299647 | 202010 | 0.04 | 1.23 | 0.03252 |
| 1299647 | 202011 | 0.01 | 1.23 | 0.00813 |
| 1299647 | 202012 | 0.01 | 1.23 | 0.00813 |
| 1301420 | 202001 | 0.01 | 1.15 | 0.008696 |
| 1301420 | 202002 | 0.04 | 1.15 | 0.034783 |
| 1301420 | 202004 | 0.15 | 1.15 | 0.130435 |
| 1301420 | 202005 | 0.22 | 1.15 | 0.191304 |
| 1301420 | 202006 | 0.22 | 1.15 | 0.191304 |
| 1301420 | 202007 | 0.22 | 1.15 | 0.191304 |
| 1301420 | 202008 | 0.15 | 1.15 | 0.130435 |
| 1301420 | 202009 | 0.08 | 1.15 | 0.069565 |
| 1301420 | 202010 | 0.04 | 1.15 | 0.034783 |
| 1301420 | 202011 | 0.01 | 1.15 | 0.008696 |
| 1301420 | 202012 | 0.01 | 1.15 | 0.008696 |
Solved! Go to Solution.
Hi @Anonymous ,
Try
Column = 'Table'[Forecast Distribution]/CALCULATE(SUM('Table'[Forecast Distribution]),ALLEXCEPT('Table','Table'[projectskey]))
Best Regards,
Jay
@Anonymous ,
use all except
example
calculate(sum(Table[column),allexcept(Table,Table[projectskey]))
Also, refer
https://community.powerbi.com/t5/Desktop/Percentage-of-subtotal/td-p/95390
Here's the Dax that give me the results of the 5th column.
Hi @Anonymous ,
Try
Column = 'Table'[Forecast Distribution]/CALCULATE(SUM('Table'[Forecast Distribution]),ALLEXCEPT('Table','Table'[projectskey]))
Best Regards,
Jay
This Dax gives me the 4th column . I wonder if it is possible to divide the 3th column by the 4 th column to obtain the results show in the 5th column without generating a circular dependency.
The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!
| User | Count |
|---|---|
| 68 | |
| 45 | |
| 43 | |
| 36 | |
| 23 |
| User | Count |
|---|---|
| 196 | |
| 126 | |
| 106 | |
| 78 | |
| 55 |