Forum Discussion
RMDNA
8 years agoSolution Sage
Create date columm from odd text format
Hi all, I'm running into an issue trying to create a date from an odd format. From the below table, we have Year, Week Num of Year, and Day of Week Num. I need to turn the first row into Febr...
- 8 years ago
HI RMDNA
Please give this calculated column a try
Column = VAR BaseDate = DATE(2018,2,1) RETURN BaseDate + ('Table 2'[DayOfWeekNum]-1) + ('Table 2'[WeekNum] * 7) - 7
Phil_Seamark
8 years agoMicrosoft Employee
- RMDNA8 years agoSolution Sage
February 1 2018 was a Thursday.
- Phil_Seamark8 years agoMicrosoft Employee
Cool, how would I know that normally? Can I hardcode that into the logic, or does the DAX need to work out other years too.
How come you need to start from 1st Feb (and not 1st Jan?)... just curious
- RMDNA8 years agoSolution Sage
The end goal of creating this date key to connect this table into my report's existing calendar table. I'm using 2018 as an example, but the data for this particular table begins 2/1/2017.
The client's fiscal year begins on February 1st, for whatever odd reason. It's definitely caused some reporting issues...