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

Score big with last-minute savings on the final tickets to FabCon Vienna. Secure your discount

Reply
akshay2204
Frequent Visitor

Subtract Row value from previous column total

I would like to have a dax query for subtracting row value from previous column total

 

Like for example the total for GP column is 63.7 and the next column CustGP the values should by 63.7 - 2.2 = 61.5 but it is showing up 74.44. 

 

The dax query which I am using is

01_GP_Cust = Sumx(All('Act vs Bud'),[001_GP_CY])-('Act vs Bud'[001_GP_CY])
akshay2204_0-1687613793049.png
Ultimately we need to calculate
GM Impact = (Total GP / Total Sales) - ((Total GP-Customer GP)/(Total Sales-Customer Sales))

 

Thanks in advance

 

1 REPLY 1
tamerj1
Super User
Super User

Hi @akshay2204 

try using ALLSELECTED instead of ALL

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.