Forum Discussion
Doubt regarding about calculating difference between dates
Hello All,
I'm having a status column and date column.I need to calculate datediff between preceding dates.How to do that?
4 Replies
- amitchandakSuper User
Try EARLIER
https://community.powerbi.com/t5/Desktop/Explanation-of-the-EARLIER-formula/td-p/529469
Appreciate your Kudos. In case, this is the solution you are looking for, mark it as the Solution. In case it does not help, please provide additional information and mark me with @
Thanks.
My Recent Blog - https://community.powerbi.com/t5/Community-Blog/Comparing-Data-Across-Date-Ranges/ba-p/823601 - v-lid-msftCommunity Support
Hi Likhitha ,
We can create a calculated table to meet your requirement:
Column = DATEDIFF ( CALCULATE ( MAX ( 'Table'[Date] ), FILTER ( 'Table', 'Table'[Date] < EARLIER ( 'Table'[Date] ) ) ), [Date], DAY )
If it doesn't meet your requirement, Please show the exact expected result based on the Tables that you have shared.
Best regards,- LikhithaHelper IV
I have one date column from which i need to calculate the net working dates with time duration.
What i have did is created a calendar table from which i calculated the sum of weekdays am achieving the networking days, but not the time included.
Can anyone help me how i can achieve networking days along with the time?
Screenshot of the raw data and the logic.
- Ashish_MathurSuper User
Hi,
Try this calculated column formula
=[Date]-CALCULATE(MAX(Data[Date]),FILTER(Data,Data[Date]<EARLIER(Data[Date])))
Hope this helps.