Forum Discussion
Raul
Post Patron
8 years agoMeasure IF Function
Hello everyone. I have the following data model: And the following measure: Invoiced = VAR LinT1= CALCULATE(SUM(T1[Import]); T1[Type]=1) VAR LinT2 = CALCULATE(SUM(T...
Raul
Post Patron
8 years agoHi v-jiascu-msft,
The result of this formula is not correct. Always return false.
Any other suggestion?
Raul
Post Patron
8 years agoOk, I have a new situation. I have managed to show in a new column (ISMASTER) into the table a 1 value if a condition is true and a 0 value if it is not. Now I need to know how to evaluate the value of each record in one measure to obtain one result or another.
This is the matrix visualization:
| CODEXPEDIENT | TOTAL | Max ISMASTER |
| E1 | $ 113,75 | 0 |
| E3 | $ 1.010,00 | 0 |
| E23 | $ 39,50 | 0 |
| E24 | $ 55,25 | 1 |
| E30 | $ - | 1 |
| E32 | $ 16,25 | 0 |
I want a new measure to obtain this result:
Measure = IF(T1.[ISMASTER] = 1; SUM(T1.[Import]); SUM(T2.[Import]))
What should be the condition of the IF function? Thank you.