Forum Discussion
conditional multiply
- 6 years ago
shei7141 here is the formula, add new column
New Col = CALCULATE ( MAX ( 'Table'[Total] ), ALLEXCEPT ( 'Table', 'Table'[UniqueID] ) ) * 'Table'[NewDis]I would ❤ Kudos if my solution helped. 👉 If you can spend time posting the question, you can also make efforts to give Kudos whoever helped to solve your problem. It is a token of appreciation!
⚡Visit us at https://perytus.com, your one-stop-shop for Power BI-related projects/training/consultancy.⚡
shei7141 you replies are very confusing, in the last reply you inked the values which were already possible from my first solution. kind of confusing what you actually want
thanks mate
but with your suggestion also, the return value was 'blank' where the total value was not filled.
Ta,
Shei
- parry2k6 years agoSuper User
shei7141 you need to revisit your question, put an excel file, and provide the calculation with the expected result. Your question is super simple and the reply has been already made but your return replies are making it super confusing. Help us to get help
- shei71416 years agoHelper III
ok this is the story
MainItem Total Sub OriginalDis NewDis A 100 a1 10% 50% A a2 15% 5 A a3 20% 20 A a4 5% 15 A a5 50% 10 B 200 b1 30% 45 B b2 25% 25 B b3 45% 30 I created the measure for Revised Fee NewTotal =
SUMX ( VALUES ('Table'[UniqueID] ),
CALCULATE ( SUM ( 'Table'[Total] ) ) * 1
)I draw a table in Vizualisation and I get the following MainItem Total Sub OriginalDis NewDis NewTotal A 100 a1 10% 50% 50 A a2 15% 5% A a3 20% 20% A a4 5% 15% A a5 50% 10% B 200 b1 30% 45% 90 B b2 25% 25% B b3 45% 30% the desirable outcome is
MainItem Total Sub OriginalDis NewDis NewTotal A 100 a1 10% 50% 50 A a2 15% 5% 5 A a3 20% 20% 20 A a4 5% 15% 15 A a5 50% 10% 10 B 200 b1 30% 45% 90 B b2 25% 25% 50 B b3 45% 30% 60 when apply the original suggestion (i.e.
New Col = CALCULATE ( MAX ( 'Table'[Total] ), ALLEXCEPT ( 'Table', 'Table'[UniqueID] ) ) * 'Table'[NewDis]
I get the following
MainItem Total Sub OriginalDis NewDis NewTotal A 100 a1 10% 50% 150 A a2 15% 5% 15 A a3 20% 20% 60 A a4 5% 15% 45 A a5 50% 10% 30 B 200 b1 30% 45% 135 B b2 25% 25% 75 B b3 45% 30% 90 - parry2k6 years agoSuper User
shei7141 this what you shared that is not working but you are not sharing what you want? and also the original solution I posted, if you used that, what is not working? Your reply/requirement is still very unclear.
Read this post to get your answer quickly.
https://community.powerbi.com/t5/Community-Blog/How-to-Get-Your-Question-Answered-Quickly/ba-p/38490