Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more
Hello, I have a beginner's question: How can I sum the values of attributes (A, B) and display the result in a new matrix for each? I created a DAX formula with SUMX, but it's not giving me the correct result. The two tables are related (1-*) with an attribute table.
Solved! Go to Solution.
@Ashish_Mathur @rajendraongole1 @Deku solved my issue! Here's the link with the solution.
I created two dimension tables (Fruit and Attribute) and established a relationship between them. The code I needed was. What do you think? Thank you
@Ashish_Mathur @rajendraongole1 @Deku solved my issue! Here's the link with the solution.
I created two dimension tables (Fruit and Attribute) and established a relationship between them. The code I needed was. What do you think? Thank you
Hello @Ashi , please here the link: https://www.dropbox.com/scl/fo/9qzy7t1nti2hgt0b2bsnr/AOXdgYX-n0wpPpMvDubjmVk?rlkey=z9g1t839bvk569oyx...
Hi,
Share the download link of the PBI file.
@rajendraongole1The code isn't working as expected. Could you review it? I might be missing something:
Hi @Charcho - For each attribute, you can create a measure that calculates the difference between the two tables.
Difference A =
SUMX(
VALUES(AttributeTable[Fruit]),
SUM(Table1[A]) - SUM(Table2[A])
)
Difference B =
SUMX(
VALUES(AttributeTable[Fruit]),
SUM(Table1[B]) - SUM(Table2[B])
)
Difference Total =
SUMX(
VALUES(AttributeTable[Fruit]),
SUM(Table1[Total]) - SUM(Table2[Total])
)
replace with your table name as per your model. Hope it works. please check.
Proud to be a Super User! | |
I would suggest first pivoting the data so that A and B are values in a single Category column. Then you put the Category column as a column header in your matrix and use a simple measure
Sum( tbl[value])
The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!
| User | Count |
|---|---|
| 37 | |
| 37 | |
| 33 | |
| 32 | |
| 29 |
| User | Count |
|---|---|
| 130 | |
| 88 | |
| 82 | |
| 68 | |
| 64 |