Forum Discussion
multiple if multiple conditions
- 3 years ago
Hi, vbis ;
The last DAX can be simplified to and could try it.
Rates = IF ( ( Clothes[Color] IN { "White", "Black" }&& [Units Sold] = "Low" ) || Clothes[Color] = "Grey", SWITCH ( [Size], "Small", "5", "Medium", "10", "Large", "15" ), "null")
Best Regards,
Community Support Team _ Yalan Wu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi, vbis ;
Perhaps you can reduce the performance of the data itself and optimize the performance. Or optimize the data itself in the power query for ETL data processing.
Best Regards,
Community Support Team _ Yalan Wu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
- vbis3 years agoHelper I
Hello.
Apparently, I still struggle with this.
I reduced the volume of the data (total number of rows now 1,408,856) and I also tried to simplify a bit the formula and i still get invalid results.
So, my dax now is:
Rates =IF ([Units Sold]="Low" && Clothes[Color]="Grey" ||[Units Sold]="Medium",SWITCH ( [Size], "Small", "5", "Medium", "10", "Large", "15" ),"0")For a number of rows i get for Medium 5 instead of 10 and for Large 10 instead of 15.What should i do to fix it?