Reformatting/Changing raw data summed in column/YTD format to row format

New Contributor
I get my raw data from a payroll provider in this format that is YTD with the months across the columns/ summed across columns. I previously received my raw data the same way I did in the table to the right where each row was an instance of data.

Is there an easy way to achieve transforming my data from that “column YTD” format to a row/per instance in rows format?

Just to test, I did paste per person, then ACCT, then ACCT #, and then the entire month column is pasted in the table in Total.I’ll add other data needed too. I have more than 3,000 rows of data and have to do this every month. Is there a better option?

I’m brand new to Power Query and doing a LinkedIn Learning course to master but is there a way to get that data in the format needed?
3 Replies


In general Power Query shall work especially if you receive your data as Excel/csv/text file. When query the source and unpivot on columns with months. Sorting by proper months order will require some manipulation and not clear from here year 2020 is taken.


Is your source data have exactly the same format / layout as in your sample file and is it in separate file or not?

Hi and thank you for helping out.

This file is a sample with random data. But it comes in that data set format on the left with the table the end result I need it in.

It’s a little busy for me to power through the Power Query LinkedIn Learning course and I really want to understand it so I’m going to make time for it now but I need this data in this format for now.


Generate by Power Query table is here


entire columns with source data are named as Range. Idea as in previous post.