Forum Discussion
Creating a Custom column based on Value from one column
- 1 year ago
Hello,
By creating a custom column in powerBI and pasting the following dax query, you will return what you are looking for. (Note that you will need to add more rows for each of your conditions.
NewColumn = SWITCH( TRUE(), SEARCH("ABC", [OriginalColumn], 1, 0) > 0, "ABC", SEARCH("EST", [OriginalColumn], 1, 0) > 0, "EST", BLANK() -- Or you can add another condition here if needed by simply repeating the above lines )Please mark my answer as the solution if this works for you, feel free to respond if you need more clarification!
Have a great day
Hi Anonymous
For last 4 entry according to your table you can use.
https://learn.microsoft.com/en-us/power-bi/create-reports/desktop-add-column-from-example
https://www.youtube.com/watch?v=BSmmNgO_EOU
And I didnt understand your requirement for starting 2 entries like whats the relation, Can you explain those.
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Happy to help!
- Anonymous1 year agoNot applicable
Hi thanks for reply
Acyually the first coloumn (original coloumn) is company name and second coulmn (custom column) is group name.
i want build a custom coulumn based on which compnay falls under which group.
Thanks