Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
I have a table that has 37 columns. each column needs to be split in to rows. If I did that to one by one it is a big mess. I need a code to apply to make it all at once. Here is a sample of the table
I need to see it as
index Programming languages Integrated development environments etc..
1 python jupyter
1 null Rstudio
10 R Rstudio
10 SQL Vm/Emacs
10 Juilia null
10 Bash null
I have tried this code:
= List.Accumulate(
Table.ColumnNames(Source),
Source,
(st, cur) =>
if List.AnyTrue(List.Transform(Table.Column(st, cur), each Text.Contains(_, ";")))
then Table.SplitColumn(st, cur, Splitter.SplitTextByDelimiter(";", QuoteStyle.Csv), 6)
else st
)
But it split them in to columns not rows
I need help as soon as possible
Solved! Go to Solution.
Based on the proposed example, this script should do what is required.
An implicit assumption, for example, is that indexes are unique.
If something does not work as desired, explain well what by loading the tables (so that they can be copied, not as images) on which it does not work and indicating exactly the error and where it occurs.
Based on the proposed example, this script should do what is required.
An implicit assumption, for example, is that indexes are unique.
If something does not work as desired, explain well what by loading the tables (so that they can be copied, not as images) on which it does not work and indicating exactly the error and where it occurs.
This is amazing! it worked like a charm.
I had to replace nulls first to get it working
= Table.TransformColumns(Source,{},(x) => Replacer.ReplaceValue(x,null,""))
but overall it worked out very well
Thank you very much
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.