Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!Learn from the best! Meet the four finalists headed to the FINALS of the Power BI Dataviz World Championships! Register now
Apologies if this has been asked before or is too basic, I'm unable to solve it.
How am I able to convert the following table
Names | 01/02 | 01/02 | 02/02 | 02/02 |
| Qty | Code | Qty | Code |
X | 10 | E10 | 10 | E10 |
Y | 10 | E10 | 10 | E10 |
to
Dates | Names | Qty | Code |
01/02 | X | 10 | E10 |
02/02 | Y | 10 | E10 |
Hi,
IF what you really want is:
And your input table looks like:
then one option is:
let
Source = Excel.CurrentWorkbook(){[Name="Table11"]}[Content], // CHANGE table name here
#"Changed Type" = Table.TransformColumnTypes(Source,{{"Column1", type text}, {"Column2", type any}, {"Column3", type any}, {"Column4", type any}, {"Column5", type any}}),
#"Unpivoted Other Columns" = Table.UnpivotOtherColumns(#"Changed Type", {"Column1"}, "Attribute", "Value"),
#"Removed Columns" = Table.RemoveColumns(#"Unpivoted Other Columns",{"Attribute"}),
#"Grouped Rows" = Table.Group(#"Removed Columns", {"Column1"}, {{"All", each _, type table [Column1=nullable text, Attribute=text, Value=any]}}),
#"Added Custom" = Table.AddColumn(#"Grouped Rows", "Custom", each Table.SelectRows(#"Grouped Rows", each [Column1] = null)[All]{0}[Value]),
#"Added Custom1" = Table.AddColumn(#"Added Custom", "Custom.1", each Table.SelectRows(#"Grouped Rows", each [Column1] = "Names")[All]{0}[Value]),
#"Added Custom2" = Table.AddColumn(#"Added Custom1", "Custom.2", each Table.FromColumns(Table.ToColumns([All]) & {[Custom]} & {[Custom.1]})),
#"Filtered Rows" = Table.SelectRows(#"Added Custom2", each ([Column1] <> null) and ([Column1] <> "Names")),
#"Removed Other Columns" = Table.SelectColumns(#"Filtered Rows",{"Custom.2"}),
#"Expanded Custom.2" = Table.ExpandTableColumn(#"Removed Other Columns", "Custom.2", {"Column1", "Column2", "Column3", "Column4"}, {"Column1", "Column2", "Column3", "Column4"}),
#"Pivoted Column" = Table.Pivot(#"Expanded Custom.2", List.Distinct(#"Expanded Custom.2"[Column3]), "Column3", "Column2"),
#"Renamed Columns" = Table.RenameColumns(#"Pivoted Column",{{"Column4", "Dates"}, {"Column1", "Names"}})
in
#"Renamed Columns"
Please mark this as answer if it helped.
Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.
Check out the February 2026 Power BI update to learn about new features.
| User | Count |
|---|---|
| 16 | |
| 12 | |
| 10 | |
| 7 | |
| 6 |