Learn from the best! Meet the four finalists headed to the FINALS of the Power BI Dataviz World Championships! Register now
hello
can someone help me please
i'm woindering if it's possible to have in a return clause multiple lignes
here is the code that i'm wrinting
Solved! Go to Solution.
Hi @Anonymous
if are you looking to pass multiple logical tests, then you can use SWITCH
columns =
SWITCH(
TRUE(),
'Product'[Color] = "Red", 1,
'Product'[Color] = "Blue", 2,
'Product'[Color] = "Black", 4,
3 --else
)
btw, your question is DAX related did you wanted to recreate it in Power Query?
Hi @Anonymous
if are you looking to pass multiple logical tests, then you can use SWITCH
columns =
SWITCH(
TRUE(),
'Product'[Color] = "Red", 1,
'Product'[Color] = "Blue", 2,
'Product'[Color] = "Black", 4,
3 --else
)
btw, your question is DAX related did you wanted to recreate it in Power Query?
hello using @Mariusz Answer here is the solution may be it will help somebody
| User | Count |
|---|---|
| 15 | |
| 8 | |
| 6 | |
| 5 | |
| 5 |