Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
Hello everyone, my name is Roberto and I would like to consult if it is possible to change the calculation that is made in the Subtotal of a column.
In the following photograph the "Total" column shows the sum between the "PPTO" column and the "REAL" column, but what I would really like to see shown is the subtraction between "PPTO" and "REAL"
The "total" column does not come from a measurement and does not come from a calculation in a table, but from the functions of Power Bi.
So, is it feasible to be able to change within this functionality that is time to add, perform a subtraction?
Another alternative that I have thought of, is to create a measure that adds the income by PPTO including filters and create a measure that adds the REAL income applying filters and these two measures are subtracted. But I don't know how to apply filters to the SUM function.
I am grateful for the help and guidance.
You are on the right path when you mention creating individual measures.
Using the CALCULATE function you can set the filters you desire. It is definitely worth reading up on how CALCULATE works.
Very quickly in your case you will need something like;
PPTO Sum =
CALCULATE(
SUM([columnThatYouWantToSum]),
[columnThatContainsPPTO] = "PPTO"
)
Hope this gets you pointed in the right direction.
Proud to be a Super User! | |
Thank you very much for the advice and help.
I was able to search for information about CALCULATE and it helped me a lot, I was able to create a measurement:
Finally, I have a "Card" on which I can place the difference between "PPTO" and "REAL":
The next challenge is to be able to incorporate this new measure as a column at the end of the matrix.
Thank you very much.
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
114 | |
98 | |
86 | |
70 | |
62 |
User | Count |
---|---|
151 | |
120 | |
103 | |
87 | |
68 |