Transpose Data using PowerQuery

rileybloke

New Member
Joined
Feb 7, 2013
Messages
43
Hello,

I have data like this...

Keyp1p2p2p3p4p5p6p7p8p9p10p11
TRB012014012534353453554354354345434434434
TRB01201402423533443455455434243

<tbody>
</tbody>

I need to transpose it within PowerQuery so that it looks like this....

KeyPeriodAmt
TRB01201401P125
TRB01201401P234
TRB01201401P3353
etc etc etc

<tbody>
</tbody>

I have played with many of the functions, but haven't been able to achieve it, any advice or guidance would be great thanks.
 

Excel Facts

Using Function Arguments with nested formulas
If writing INDEX in Func. Arguments, type MATCH(. Use the mouse to click inside MATCH in the formula bar. Dialog switches to MATCH.
PQ has an Unpivot function (in the Transpose tab), using that and renaming the columns gives the following M code

Code:
let    Source = Excel.CurrentWorkbook(){[Name="Table3"]}[Content],
    #"Unpivoted Columns" = Table.UnpivotOtherColumns(Source, {"Key"}, "Attribute", "Value"),
    #"Renamed Columns" = Table.RenameColumns(#"Unpivoted Columns",{{"Attribute", "Period"}, {"Value", "Amt"}})
in
    #"Renamed Columns"
 
Upvote 0

Forum statistics

Threads
1,215,219
Messages
6,123,687
Members
449,117
Latest member
Aaagu

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top