Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more. Get started
Hi, im trying to create a custom column to return the month , not having much luck, heres my column:
[Month_Type] Azure July 2022
I just want to get the month in another column please
Solved! Go to Solution.
Hi @dommyw277
You could create a column as below:-
month_col =
SWITCH (
TRUE (),
CONTAINSSTRING ( table[_column], "January" ), "January",
CONTAINSSTRING ( table[_column], "February" ), "February",
CONTAINSSTRING ( table[_column], "March" ), "March",
CONTAINSSTRING ( table[_column], "April" ), "April",
CONTAINSSTRING ( table[_column], "May" ), "May",
CONTAINSSTRING ( table[_column], "June" ), "June",
CONTAINSSTRING ( table[_column], "July" ), "July",
CONTAINSSTRING ( table[_column], "August" ), "August",
CONTAINSSTRING ( table[_column], "September" ), "September",
CONTAINSSTRING ( table[_column], "October" ), "October",
CONTAINSSTRING ( table[_column], "November" ), "November",
CONTAINSSTRING ( table[_column], "December" ), "December"
)
Best Regards,
Samarth
If this post helps, please consider accepting it as the solution to help the other members find it more quickly.
Appreciate your Kudos!!
Connect on Linkedin
Can you show me the original column?
Hi @dommyw277
You could create a column as below:-
month_col =
SWITCH (
TRUE (),
CONTAINSSTRING ( table[_column], "January" ), "January",
CONTAINSSTRING ( table[_column], "February" ), "February",
CONTAINSSTRING ( table[_column], "March" ), "March",
CONTAINSSTRING ( table[_column], "April" ), "April",
CONTAINSSTRING ( table[_column], "May" ), "May",
CONTAINSSTRING ( table[_column], "June" ), "June",
CONTAINSSTRING ( table[_column], "July" ), "July",
CONTAINSSTRING ( table[_column], "August" ), "August",
CONTAINSSTRING ( table[_column], "September" ), "September",
CONTAINSSTRING ( table[_column], "October" ), "October",
CONTAINSSTRING ( table[_column], "November" ), "November",
CONTAINSSTRING ( table[_column], "December" ), "December"
)
Best Regards,
Samarth
If this post helps, please consider accepting it as the solution to help the other members find it more quickly.
Appreciate your Kudos!!
Connect on Linkedin
Select that column and then go to Add Column > Extract > Text Between Delimiters.
On the Start and End delimiter insert a space.
Then open advanced options and change "Number of start delimiters to skip" to 1.
Thans, this is what it gives me though
Check out the September 2024 Power BI update to learn about new features.
Learn from experts, get hands-on experience, and win awesome prizes.
User | Count |
---|---|
104 | |
98 | |
97 | |
38 | |
37 |
User | Count |
---|---|
152 | |
121 | |
73 | |
71 | |
63 |