I have a data table containing rows of monthly data, similar to below,
<tbody>
</tbody>
I would like to use Power Query to create a table that outputs the following:
<tbody>
</tbody>
This assumes that the "current" month is September 2016 (not necessarily always the latest month of the data, so the month designated as current needs to be a parameter type selection).
At first I thought this would be fairly simple but when I actually started working on it, I am drawing a blank.
Customer | Period | Volume | Revenue | Margin |
A | 8/1/2016 | 30 | 20 | 10 |
A | 9/1/2016 | 30 | 20 | 10 |
B | 7/1/2016 | 10 | 5 | 2 |
B | 9/1/2016 | 8 | 4 | 2 |
<tbody>
</tbody>
I would like to use Power Query to create a table that outputs the following:
Customer | MTD - Volume | MTD - Revenue | MTD - Margin | YTD - Volume | YTD - Revenue | YTD - Margin |
A | 30 | 20 | 10 | 60 | 40 | 20 |
B | 8 | 4 | 2 | 18 | 9 | 4 |
<tbody>
</tbody>
This assumes that the "current" month is September 2016 (not necessarily always the latest month of the data, so the month designated as current needs to be a parameter type selection).
At first I thought this would be fairly simple but when I actually started working on it, I am drawing a blank.