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 have a column of data, which is in date format dd/mm/yy.
I need to change every date in the column that is earlier than 01/01/18, to show 01/01/18. So, if the date is 04/02/18, then it stays as it is, however if the date is 08/12/17, then it needs to show as 01/01/18.
I've tried various formulae with no success...
GanttStartDate = IF(Projects[ProjectStartDate].[Date]<01/01/18,01/01/18,Projects[ProjectStartDate].[Date])
GanttStartDate = IF(Projects[ProjectStartDate]<01/01/18,01/01/18,Projects[ProjectStartDate].[Date])
GanttStartDate = IF(Projects[ProjectStartDate]<01/01/18,01/01/18,Projects[ProjectStartDate])
Can anyone please advise a suitable formula?
Many thanks,
Rich
Solved! Go to Solution.
try this
GanttStartDate = IF(Projects[ProjectStartDate]<DATE(2018,01,01),DATE(2018,01,01),Projects[ProjectStartDate])
use dax function DATE()
try this
GanttStartDate = IF(Projects[ProjectStartDate]<DATE(2018,01,01),DATE(2018,01,01),Projects[ProjectStartDate])
use dax function DATE()
You, my friend, are wonderful
Thanks so much.
I even like the touch of missing out the closing square bracket after projectstartdate, so I didn't just copy paste!
Cheers,
Rich
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 |
---|---|
109 | |
99 | |
77 | |
66 | |
54 |
User | Count |
---|---|
144 | |
104 | |
102 | |
87 | |
64 |