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
Uzi2019
Super User
Super User

Divide Row value with Sub Total

Hello Expert,
I need your help in getting the row subtotal value. I have given the example:

Uzi2019_2-1676448186376.png

 

 


I am not able to get the sub total value through meaure. beacuse i need to divide row value with sub total value like(600,180,50,20).
Please help me to get the sub total value.

Thank you in advance

 

Don't forget to give thumbs up and accept this as a solution if it helped you!!!
1 ACCEPTED SOLUTION
Tahreem24
Super User
Super User

@Uzi2019 Try this DAX Measure:
Measure = 

VAR _Curr = SUM(Table[Spends])
VAR _All = CALCULATE(_Curr,REMOVEFILTERS(Table[Product]))
RETURN DIVIDE(_Curr,_All,0)
 
Don't forget to give thumbs up and accept this as a solution if it helped you!!!

Please take a quick glance at newly created dashboards : Restaurant Management Dashboard , HR Analytics Report , Hotel Management Report, Sales Analysis Report , Fortune 500 Companies Analysis , Revenue Tracking Dashboard

View solution in original post

6 REPLIES 6
Tahreem24
Super User
Super User

@Uzi2019 Try this DAX Measure:
Measure = 

VAR _Curr = SUM(Table[Spends])
VAR _All = CALCULATE(_Curr,REMOVEFILTERS(Table[Product]))
RETURN DIVIDE(_Curr,_All,0)
 
Don't forget to give thumbs up and accept this as a solution if it helped you!!!

Please take a quick glance at newly created dashboards : Restaurant Management Dashboard , HR Analytics Report , Hotel Management Report, Sales Analysis Report , Fortune 500 Companies Analysis , Revenue Tracking Dashboard

Thanks @Tahreem24 
Your solution actually works for me.

Don't forget to give thumbs up and accept this as a solution if it helped you!!!
v-zhangti
Community Support
Community Support

Hi, @Uzi2019 

 

You can try the following methods.
Sample data:

vzhangti_0-1676616935842.png

Measure = 
Var _N1=SUM('Table'[Value])
Var _N2= CALCULATE(SUM('Table'[Value]),ALLEXCEPT('Table','Table'[Region],'Table'[Category]))
Return
DIVIDE(_N1,_N2)

vzhangti_1-1676616971841.png

Is this the result you expect?

 

Best Regards,

Community Support Team _Charlotte

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

@v-zhangti  Thanks for your reply. I tried this already but I have few slicers of Year,Month, etc. when we select any value from slicer so measure values remain constant. I used ALLSELECTED as well but measure value is not changing as per slicer value selected.

Don't forget to give thumbs up and accept this as a solution if it helped you!!!

Hi, @Uzi2019 

 

Please provide sample data and expected output. Sensitive information can be removed in advance.

 

Best Regards

@v-zhangti Pasting smaple data and output below: (Measure should be working as per any value selected in Slicer by end user)
Expected Output:

RegionCategoryProductSpendsMeasure
EastAAR KU1000.166666667
East LE FU200200/600
East  YUMM300300/600
East Total600600/600
EastBGO CR5050/180
East GO HA6060/180
East GO PO7070/180
East Total180180/180
NorthA POPP2020/50
North S GOU3030/50
North Total5050/50
NorthBAARA 2020/40
North N POT2020/40
North Total4020/20

 

Sample Data:

RegionsCategoryBrandQuantityYearMonth
EastAGO TE292022Jan
EastAAR KU9462022Feb
EastAAR KU9622022Mar
EastALE FU6342022Apr
EastA YUMM6772022May
EastBAJI K-372022Jun
EastBITOS 12302022Jul
EastBITOS 14012022Aug
EastBSER-D-352022Sept
EastCGO NO5502022Oct
EastCX FRI22022Nov
EastC YUMM-362022Dec
EastCAPURN-372022Jan
EastDGO CR6352022Feb
EastDGO HA7572022Mar
EastDGO PO24892022Apr
EastDGO WA12782022May
EastD POPP-372022Jun
EastDS GOU422022Jul
EastDS SIZ26872022Aug
EastDS WAF20662022Sept
EastDAARA -372022Oct
EastDN POT-372022Nov
EastDAL MA-372022Dec
EastD YUMM-62023Jan
EastD II D2042023Feb
EastD II H13682023Mar
EastFGO MA19932023Apr
EastFCRAX -342023May
EastFX COR6412023Jun
EastFX CUR1522023Jul
EastFAR KU1512023Aug
EastFAR KU2152023Sept
EastFAR PA-372023Oct
EastF YUMM2202023Nov
EastFLOW D8292023Dec
EastGDH NA-372023Jan
EastGAJI B-252023Feb
EastGAJI M-342023Mar
EastGAJI S-342023Apr
EastGAJI T-372023May
EastGANO B-362023Jun
EastGK FAR-372023Jul
EastGMUKHA-372023Aug
EastG SNAC-372023Sept
EastGUJI N-372023Oct
EastGDIRAM-372023Nov
EastGDIRAM-362023Dec
Don't forget to give thumbs up and accept this as a solution if it helped you!!!

Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

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

August 2025 community update carousel

Fabric Community Update - August 2025

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