I'm trying to create a dynamic date dimension using Power Query, as outlined in articles such as
https://www.powerquery.training/portfolio/dynamic-calendar-table/
https://blog.crossjoin.co.uk/2013/11/19/generating-a-date-dimension-table-in-power-query/
This comes very close, but the date dimension I want to build needs a few additional considerations:
- I have a fact table with a listing of dates, representing the Period. Therefore, they will always be the 1st of the month, such as 1/1/2016, 2/1/2016, 3/1/2016, etc.
- In my date dimension, I want the StartDate to be January 1 of the minimum year in my Period column of the fact table ... and I want EndDate to be December 1 of the maximum date in my fact table Period column
- I want the date dimension to increment by month, not day
I'm having a hard time modifying the queries in the articles above to meet these requirements. I was wondering if anyone could offer any advice?
https://www.powerquery.training/portfolio/dynamic-calendar-table/
https://blog.crossjoin.co.uk/2013/11/19/generating-a-date-dimension-table-in-power-query/
This comes very close, but the date dimension I want to build needs a few additional considerations:
- I have a fact table with a listing of dates, representing the Period. Therefore, they will always be the 1st of the month, such as 1/1/2016, 2/1/2016, 3/1/2016, etc.
- In my date dimension, I want the StartDate to be January 1 of the minimum year in my Period column of the fact table ... and I want EndDate to be December 1 of the maximum date in my fact table Period column
- I want the date dimension to increment by month, not day
I'm having a hard time modifying the queries in the articles above to meet these requirements. I was wondering if anyone could offer any advice?