Power BI is turning 10, and we’re marking the occasion with a special community challenge. Use your creativity to tell a story, uncover trends, or highlight something unexpected.
Get startedJoin us for an expert-led overview of the tools and concepts you'll need to become a Certified Power BI Data Analyst and pass exam PL-300. Register now.
Is it possible to create an abberanding total in a matrix? This for bookkeeping purpopes?
What I have now is (red is wrong):
Revenues:
Revenue 1 1.000
Revenue 2 2.000
Total Revenues: 3.000
Costs:
Cost 1 1.000
Cost 2 400
Total Costs: 1.400
TOTAL: 4.400
What I want is Total to be 1.600 (3000 - 1400), but without having the Costs also as a negative value. What I was able to create is (red is wrong):
Revenues:
Revenue 1 1.000
Revenue 2 2.000
Total Revenues: 3.000
Costs:
Cost 1 -1.000
Cost 2 -400
Total Costs: -1.400
TOTAL: 1.600
What I want:
Revenues:
Revenue 1 1.000
Revenue 2 2.000
Total Revenues: 3.000
Costs:
Cost 1 1.000
Cost 2 400
Total Costs: 1.400
TOTAL: 1.600
But I was not able to create this....
Who can help me?
Solved! Go to Solution.
hi @MiKeZZa
you can create a new measure to obtain this result:
ValueRV = VAR REVENUE = CALCULATE ( SUM ( Table1[Value] ), Table1[Type] = "REVENUE" ) VAR COSTS = CALCULATE ( SUM ( Table1[Value] ), Table1[Type] = "COSTS" ) RETURN IF ( HASONEVALUE ( Table1[Type] ), CALCULATE ( SUM ( Table1[Value] ) ), REVENUE - COSTS )
And Use it in values Section in Matrix Visual.
hi @MiKeZZa
you can create a new measure to obtain this result:
ValueRV = VAR REVENUE = CALCULATE ( SUM ( Table1[Value] ), Table1[Type] = "REVENUE" ) VAR COSTS = CALCULATE ( SUM ( Table1[Value] ), Table1[Type] = "COSTS" ) RETURN IF ( HASONEVALUE ( Table1[Type] ), CALCULATE ( SUM ( Table1[Value] ) ), REVENUE - COSTS )
And Use it in values Section in Matrix Visual.
This works like a charm! Thank you!
This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.
Check out the June 2025 Power BI update to learn about new features.
User | Count |
---|---|
72 | |
70 | |
55 | |
37 | |
31 |
User | Count |
---|---|
83 | |
64 | |
63 | |
49 | |
45 |