Calculating sum on other calculated field ( whih are also sum of different fields)

Hey team.

So I have 2 calculated fields - sum1 and sum2 created in the quiksight pivot table.

Now I want to use those calculated field to get another calculated field for the pivot. How can i do that, I have multiples way to do it but the result isnt correct in the pivot.

sum1 = a+b+c
sum2 = d+e

i want
sum3 = sum2 - sum1
but this isnt happening.

The data for a-e is 1s and 0s which aggregate by groups in the pivot table.

I even tried
sum3 = d+e-a-b-c but this also does not work.

Let me know how can i make this work.

can you share an example with numbers and screenshot of the table?

Hey, it got solved, you can close this issuse. thank you