Forum Discussion
Naveen29
2 years agoHelper II
DAX help needed
My current matrix table in the PowerBI showing like table A: Dont want to change M query ,table relationships etc. I just need simple DAX which converts the Region values to Negative , and sum should...
- Anonymous2 years ago
Hi Naveen29 ,
According to your description, here are my steps you can follow as a solution.
(1) My test data is the same as yours.
(2) We can create two measures.
Measure = IF(MAX('Table'[Region])="Region",-SUM('Table'[Value]),SUM('Table'[Value]))Measure 2 = SUMX(VALUES('Table'[Region]),[Measure])(3) Then the result is as follows.
If the above one can't help you get the desired result, please provide some sample data in your tables (exclude sensitive data) with Text format and your expected result with backend logic and special examples. It is better if you can share a simplified pbix file. Thank you.
Best Regards,
Neeko Tang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
- 2 years ago
You can create Calculated column for that
Negative Sales = IF('Summerized table'[Country] = "Mexico", 0 -'Summerized table'[ Sales],'Summerized table'[ Sales])
Aditya062
2 years agoFrequent Visitor
You can create Calculated column for that
Negative Sales = IF('Summerized table'[Country] = "Mexico", 0 -'Summerized table'[ Sales],'Summerized table'[ Sales])