I have a PowerQuery table called "On Holds" in Excel as below:
| Action User | Index |
|-------------|-------|
| Employee A | 1 |
| Employee B | 1 |
| Employee B | 1 |
| Employee B | 1 |
| Employee C | 1 |
| Employee C | 1 |
| Employee C | 1 |
| Employee C | 1 |
| Employee C | 1 |
| Employee D | 1 |
| Employee D | 1 |
| Employee D | 1 |
I'm looking to convert it to look like this (it'll have column headers, but I'm not bothered what they are):
| Employee A | 1 | | | | |
| Employee B | 1 | 1 | 1 | | |
| Employee C | 1 | 1 | 1 | 1 | 1 |
| Employee D | 1 | 1 | 1 | | |
I have a separate table (TeamMembers) that lists unique employee names that I've tried joining to create this list but ultimately end up with versions similar to the original table.
I could do it with VBA or a series of Transpose formula outside of Powerquery but feel this isn't the best way to go - formula would need updating each week to take into account the different number of rows.
Any help would be greatly appreciated.
A basic transpose doesn't work as it ends up like this:
| Column1 | Column2 | Column3 | Column4 | Column5 | Column6 |
|------------|------------|------------|------------|------------|------------|
| Employee A | Employee B | Employee B | Employee B | Employee C | Employee C |
| 1 | 1 | 1 | 1 | 1 | 1 |
A pivot ends up like this:
| Employee A | Employee B | Employee C | Employee D |
|------------|------------|------------|------------|
| 1 | 3 | 5 | 3 |
