Forum Discussion
FrankWoody
4 years agoHelper I
M Language Extract Text
I would like to create some criteria when extracting the text based on the number of "-" and the text of the column starting with "ABLE TO PLAY". If the column starts with the text "ABLE TO PLAY" an...
- 4 years ago
= Table.AddColumn(#"Renamed Columns", "Custom",
each if
Text.Length(Text.Select([_5],"-"))>1 and Text.StartsWith([_5],"ABLE TO PLAY")
then Text.BetweenDelimiters([_5], "-", "-", 0, 1)
else if
Text.Length(Text.Select([_5],"-"))<=1 and Text.StartsWith([_5], "ABLE TO PLAY")
then Text.AfterDelimiter([_5], " ", 2) else [_5])
Achieve after testing a lot! If anyone has the same problem or something similar I hope it helps.
Hariharan_R
4 years agoSolution Sage
Hi,
Will you able to share some sample records?
Thanks
Hari