Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
Hi,
I am trying to change calendar dates in my report to financial.
My method to do this was to create a new table then match on to the date Key.
Date =
GENERATE (
CALENDAR ( DATE ( 2014, 1, 1 ), DATE ( 2021, 12, 31 ) ),
VAR currentDay = [Date]
VAR day = DAY( currentDay )
VAR month = MONTH ( currentDay )
VAR year = YEAR ( currentDay )
VAR FiscalQuarter = IF(month=1,"4",IF(month=2,"4",IF(month=3,"4",IF(month=4,"1",IF(month=5,"1",IF(month=6,"1",IF(month=7,"2",IF(month=8,"2",IF(month=9,"2",IF(month=10,"3",IF(month=11,"3",IF(month=12,"3"))))))))))))
VAR FY = IF(month<=3,"FY"&RIGHT(year-1,2),"FY"&RIGHT(year,2))
RETURN ROW (
"day", day,
"month", month,
"year", year,
"quarter", FiscalQuarter,
"fy", FY ))
My other table has the key as dd/mm/yyyy format.
The tables are not matching. I merged them on date as 1 to 1.
Is it because the new table includes a time stamp of 00:00:00?
If so, I changed this in the modelling format ribbon but it still does not merge when I try to create a matrix, using the new financial dates from the new table.
Thanks
Solved! Go to Solution.
I solvd this.
I had to change the formats in the modelling to both the exact same.
Strangely it changed the date to a text field in the column not created by DAX
I solvd this.
I had to change the formats in the modelling to both the exact same.
Strangely it changed the date to a text field in the column not created by DAX
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
107 | |
98 | |
81 | |
65 | |
62 |
User | Count |
---|---|
147 | |
116 | |
104 | |
88 | |
65 |