Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Get certified in Microsoft Fabric—for free! For a limited time, get a free DP-600 exam voucher to use by the end of 2024. Register now

Reply
joshua1990
Post Prodigy
Post Prodigy

Convert Year-Week to Date within PQ or DAX

Hi all!

I have a huge transactional table that contains a year-week column.

This column is based on a fiscal calendar and the 445 approach.

To get a 1:n realtion between all tables, I need a date. Here I always use the Monday (start of the week). 

My question is now, what is better?

  1. Compute it in Power Query?
  2. Or convert it in DAX?

What would you preffer and what would be the approach / function itself?

 

Best regards

Joshua

2 REPLIES 2
Aurelio
Frequent Visitor

Hello Joshua


I would create a date table: 

Use this code to create the Date-column

 
DATE = CALENDAR(DATE(2008,1,1),DATE(2035,12,31))
 

week. Normally you can create with this column the relationship to your transactional table. 

 

PS: Year-Week = YEAR(Dates[date]) && WEEKNUM(dates[date],1). 

 

Hi thanks, but this was not my question.

Helpful resources

Announcements
November Carousel

Fabric Community Update - November 2024

Find out what's new and trending in the Fabric Community.

Live Sessions with Fabric DB

Be one of the first to start using Fabric Databases

Starting December 3, join live sessions with database experts and the Fabric product team to learn just how easy it is to get started.

Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Early Bird pricing ends December 9th.

Nov PBI Update Carousel

Power BI Monthly Update - November 2024

Check out the November 2024 Power BI update to learn about new features.