Forum Discussion
Anonymous
6 years agoNot applicable
Extract Text
Hi, I have few Product descriptions with me eg: HP 16GB (1X16GB) 2RX4 PC3L-12800R HP 16GB(1X16GB) 2RX4 PC3L-12800R HPE 16GB 1RX4 PC4-2400T-R DIMM 16GB PC4-2933 DUAL-RANK X8 DDR4 8GB PC4-2933 SIN...
- Anonymous6 years ago
power Query, add Conditional column
mahoneypat
6 years agoMicrosoft Employee
You can add a custom column in the query editor with this formula. It worked with your sample data (replace [TextColumn] with your actual column name), but you may have to adapt it, if there are scenarios not covered.
= List.First(List.Transform(List.Select(Text.Split([TextColumn], " "), each Text.Contains(_, "GB")), each Text.BeforeDelimiter(_, "GB") & "GB"), ", ")
If this works for you, please mark it as the solution. Kudos are appreciated too. Please let me know if not.
Regards,
Pat