Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Reply
Anonymous
Not applicable

Calculate cumulative % in Table

Hi,
I have requirement. to calcualte cummalative % and to Show Total Liters in table chart. i tried using dax measure but it is not giving correct result. Please help
i need calculate % Running total - Example IT60 - it should give 18%
US 21 - 18%+13% = 31%
PE10 = 18%+13%+10%= 41% and so on
i have tried by using Quick Measure - Running total as below screenshot and it is not giving Proper result 


Note - Total Liters is sorted as Descending order

LikhithaVG123_0-1678201479369.png

Thanks

 

5 REPLIES 5
andhiii079845
Solution Sage
Solution Sage

From which table is "receiving plant"? I think this is the problem. please share the underlaying datamodel and tables.

You also say now "Total litre measure". You do not mentioned it before that is is a measure. Please share the measure.

 





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!




Anonymous
Not applicable

Hi @andhiii079845 
Total Liters and % are measures, and need to calculate Cummalative % (To show Total Liters as highest to lowest in table chart)

Total liters = 

CALCULATE( sumx(
 tbl_cses_salesordertransit_rpt, tbl_cses_salesordertransit_rpt[Liters/Case] * tbl_cses_salesordertransit_rpt[OrderQuantity])

% =DIVIDE(sum(tbl_cses_salesordertransit_rpt[Total Liters FG]),[Sum of Total Litres FG])

LikhithaVG123_0-1678275267146.png

Thanks

Can you please give a full example of all involved tables, the relation and with some data examples. It is for me not clear in the moment where the problem is. 





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!




andhiii079845
Solution Sage
Solution Sage

Hi,

try this. Change the table name which I used. 

running total % = 

 VAR _currentlilter = maxx(table2,table2[Total liters])
 VAR _total = sumx(ALLSELECTED(table2),table2[Total liters])
 VAR _currenttotal = sumx(FILTER(ALLSELECTED(table2),table2[Total liters]<=_currentlilter),table2[Total liters])

 RETURN _currenttotal/_total
 
andhiii079845_0-1678218403689.png

Mark my post as a solution if it was helpfull.





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!




Anonymous
Not applicable

Hi @andhiii079845 
I have tried your solution in calculated column but it is giving result as 100% for all values. Please help on this

calculated column - running total % colum =


 VAR _currentlilter = maxx(tbl_cses_salesordertransit_rpt,tbl_cses_salesordertransit_rpt[Total Liters FG])
 VAR _total = sumx(ALLSELECTED(tbl_cses_salesordertransit_rpt),tbl_cses_salesordertransit_rpt[Total Liters FG])
 VAR _currenttotal = sumx(FILTER(ALLSELECTED(tbl_cses_salesordertransit_rpt),tbl_cses_salesordertransit_rpt[Total Liters FG]<=_currentlilter),tbl_cses_salesordertransit_rpt[Total Liters FG])

 RETURN _currenttotal/_total
 
LikhithaVG123_1-1678274379199.png

Thanks

 

Helpful resources

Announcements
July 2025 community update carousel

Fabric Community Update - July 2025

Find out what's new and trending in the Fabric community.

July PBI25 Carousel

Power BI Monthly Update - July 2025

Check out the July 2025 Power BI update to learn about new features.