Check your eligibility for this 50% exam voucher offer and join us for free live learning sessions to get prepared for Exam DP-700.
Get StartedDon't miss out! 2025 Microsoft Fabric Community Conference, March 31 - April 2, Las Vegas, Nevada. Use code MSCUST for a $150 discount. Prices go up February 11th. Register now.
I want to show task slippage from a project schedule in hours. Closed tasks should be against the planned and actual date/time and all open tasks against the current date/time. Using the suggested answer from: http://community.powerbi.com/t5/Desktop/How-to-subtract-a-column-with-Date-and-time-from-current-tim... I derived:
Column: HourlyFinishVariance = IF(ISBLANK('Tasks'[TaskActualFinishDate].[Date]), if(Tasks[TaskFinishDate].[Date]>NOW(), -DATEDIFF(NOW(),Tasks[TaskFinishDate].[Date],HOUR),DATEDIFF(Tasks[TaskFinishDate].[Date],NOW(),HOUR)), IF(Tasks[TaskFinishDate].[Date]>Tasks[TaskActualFinishDate].[Date], -DATEDIFF(Tasks[TaskActualFinishDate].[Date],Tasks[TaskFinishDate].[Date],HOUR),DATEDIFF(Tasks[TaskFinishDate].[Date],Tasks[TaskActualFinishDate].[Date],HOUR)))
It seems to work ok for closed tasks but doesn't seem to be returning the correct answer for open tasks. It's only returning values like 23hrs or 47hrs (almost 24hr clock less an hour):
Hi @nogi,
After check, the syntax of formula is right? Could you please share your sample date for further analysis? Do hide sensitive information when you upload it. Or you can create dummy sample table if your data is private.
Best Regards,
Angelia
User | Count |
---|---|
117 | |
74 | |
62 | |
50 | |
45 |
User | Count |
---|---|
174 | |
125 | |
60 | |
60 | |
57 |