Power BI is turning 10, and we’re marking the occasion with a special community challenge. Use your creativity to tell a story, uncover trends, or highlight something unexpected.
Get startedJoin us for an expert-led overview of the tools and concepts you'll need to become a Certified Power BI Data Analyst and pass exam PL-300. Register now.
Hello,
I'm quite new to DAX. I need your help for transforming a table from somthing like:
Name | Type
A | f,g
B | f,i,h
C | p
into something like:
Name | Type
A | f
A | g
B | f
B | i
B | h
C | p
Thanks in advance!
Solved! Go to Solution.
Hi @Anonymous
you can do it like this:
let Source = Table.FromRows(Json.Document(Binary.Decompress(Binary.FromText("i45WclTSUUrTSVeK1YlWcgKzM3UywDxnIK9AKTYWAA==", BinaryEncoding.Base64), Compression.Deflate)), let _t = ((type text) meta [Serialized.Text = true]) in type table [Name = _t, Type = _t]), ChangedType = Table.TransformColumnTypes(Source,{{"Name", type text}, {"Type", type text}}), SplitColumnbyDelimiter = Table.ExpandListColumn(Table.TransformColumns(ChangedType, {{"Type", Splitter.SplitTextByDelimiter(",", QuoteStyle.Csv), let itemType = (type nullable text) meta [Serialized.Text = true] in type {itemType}}}), "Type") in SplitColumnbyDelimiter
Did I answer your question correctly? Mark my answer as a solution!
Proud to be a Datanaut!
Hi @Anonymous
you can do it like this:
let Source = Table.FromRows(Json.Document(Binary.Decompress(Binary.FromText("i45WclTSUUrTSVeK1YlWcgKzM3UywDxnIK9AKTYWAA==", BinaryEncoding.Base64), Compression.Deflate)), let _t = ((type text) meta [Serialized.Text = true]) in type table [Name = _t, Type = _t]), ChangedType = Table.TransformColumnTypes(Source,{{"Name", type text}, {"Type", type text}}), SplitColumnbyDelimiter = Table.ExpandListColumn(Table.TransformColumns(ChangedType, {{"Type", Splitter.SplitTextByDelimiter(",", QuoteStyle.Csv), let itemType = (type nullable text) meta [Serialized.Text = true] in type {itemType}}}), "Type") in SplitColumnbyDelimiter
Did I answer your question correctly? Mark my answer as a solution!
Proud to be a Datanaut!
Thanks, that's solved the problem like a charm!
This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.
Check out the June 2025 Power BI update to learn about new features.
User | Count |
---|---|
78 | |
75 | |
58 | |
36 | |
33 |
User | Count |
---|---|
100 | |
62 | |
56 | |
47 | |
41 |