Forum Discussion
Anonymous
4 years agoNot applicable
extract text after delimiter using a delimiter column
I have a [target] column and a [delimiter] column. The [delimiter] column has values that I want to use as delimiter for the [target] column's values. How can I extract text after delimiter (the [d...
- 4 years ago
If you want result in another column and
= Text.AfterDelimiter([target],[delimiter])For in column replacement, insert following statement i.e. not create another column
= Table.ReplaceValue(Source,each [target],each Text.AfterDelimiter([target],[delimiter]),Replacer.ReplaceValue,{"target"})See the working here - Open a blank query - Home - Advanced Editor - Remove everything from there and paste the below code to test
let Source = Table.FromRows(Json.Document(Binary.Decompress(Binary.FromText("i45WSqxJUtJRqlGK1YlWSk7xzNLJzskFCugoxcYCAA==", BinaryEncoding.Base64), Compression.Deflate)), let _t = ((type nullable text) meta [Serialized.Text = true]) in type table [target = _t, delimiter = _t]), Custom1 = Table.ReplaceValue(Source,each [target],each Text.AfterDelimiter([target],[delimiter]),Replacer.ReplaceValue,{"target"}) in Custom1
Vijay_A_Verma
Most Valuable Professional
4 years agoIf you want result in another column and
= Text.AfterDelimiter([target],[delimiter])For in column replacement, insert following statement i.e. not create another column
= Table.ReplaceValue(Source,each [target],each Text.AfterDelimiter([target],[delimiter]),Replacer.ReplaceValue,{"target"})See the working here - Open a blank query - Home - Advanced Editor - Remove everything from there and paste the below code to test
let
Source = Table.FromRows(Json.Document(Binary.Decompress(Binary.FromText("i45WSqxJUtJRqlGK1YlWSk7xzNLJzskFCugoxcYCAA==", BinaryEncoding.Base64), Compression.Deflate)), let _t = ((type nullable text) meta [Serialized.Text = true]) in type table [target = _t, delimiter = _t]),
Custom1 = Table.ReplaceValue(Source,each [target],each Text.AfterDelimiter([target],[delimiter]),Replacer.ReplaceValue,{"target"})
in
Custom1