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.
So I have a table (KPIs) with completed dates. I was easily able to get a calculated column for the most recent date......
Is_LastDate = IF(KPIs[date_completed] = MAX(KPIs[date_completed]), 1, 0)
However, I now want another calculated column that does the same thing, but for the last date in the previous quarter. It would look like this.
date_completed Is_LastDatePrevQtr
7/15/2019 0
6/2/2019 0
5/15/2019 0
3/30/2019 1
2/15/2019 0
1/13/2019 0
I can't figure out the DAX though.
Solved! Go to Solution.
HI @benjaminlperry ,
I think you can use date function to calculate with date fields to find out specific date who added three months(one quarter) equal to max date.
PrevLastdate = IF ( DATE ( YEAR ( 'Table'[Date] ), MONTH ( 'Table'[Date] ) + 3, DAY ( 'Table'[Date] ) ) = MAX ( 'Table'[Date] ), 1, 0 )
Regards,
Xiaoxin Sheng
HI @benjaminlperry ,
I think you can use date function to calculate with date fields to find out specific date who added three months(one quarter) equal to max date.
PrevLastdate = IF ( DATE ( YEAR ( 'Table'[Date] ), MONTH ( 'Table'[Date] ) + 3, DAY ( 'Table'[Date] ) ) = MAX ( 'Table'[Date] ), 1, 0 )
Regards,
Xiaoxin Sheng
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 |
---|---|
110 | |
98 | |
78 | |
64 | |
55 |
User | Count |
---|---|
143 | |
109 | |
89 | |
84 | |
66 |