Forum Discussion
Dax Switch with multiple answers
- Anonymous4 years ago
Hi Gregory-N ,
I create a table to test according to your descriptions.
Please try below steps:
1. below is my test table
Table:
2. in power query, split a column by delimiter and split to row(Split a column of text (Power Query) (microsoft.com))
3. load into Power BI and add a new column with below dax formula
Column = SWITCH ( 'Table'[Safety Icon], 1, "Health & Happiness", 2, "Equity & Local Economy", 3, "Culture & Community", "no" )Please refer the attached .pbix file.
Best regards,
Community Support Team_ Binbin Yu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi Gregory-N ,
I create a table to test according to your descriptions.
Please try below steps:
1. below is my test table
Table:
2. in power query, split a column by delimiter and split to row(Split a column of text (Power Query) (microsoft.com))
3. load into Power BI and add a new column with below dax formula
Column =
SWITCH (
'Table'[Safety Icon],
1, "Health & Happiness",
2, "Equity & Local Economy",
3, "Culture & Community",
"no"
)
Please refer the attached .pbix file.
Best regards,
Community Support Team_ Binbin Yu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
- Gregory-N4 years agoRegular Visitor
Thank you