on 12-20-2016 10:10 AM
Hi experts,
I have the following chalange:
There are two given dates: [date-1] and [date-2]. The difference of these two dates has to be calculated like [date-2] - [date-1] and the result needs to be in the following format: dddd HH:mm:ss (days hours:minutes:seconds).
A solution has been created by me, but it uses quite a lot of variables and functions - it is very complicated and not easy to understand!
My question is, if there is an easier way to do this - maybe there is a function that I am not aware of?
Any hint is appreciated!
TIA,
Henning
Is "234" the days between those two dates? if yes, you can try the below:
=DaysBetween([Date2];[Date1]) + " " + formatdate(Relativedate([Date2];-DaysBetween([Date2];[Date1]));"hh:mm:ss")
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Seemd as a good idea in the first place, but it unfortunately produces wrong results:
The format in the column "Time Difference" is wrong - I am not looking for a date format, but actually for the number of days, i.e. "234 12:34:56" would be the desired result.
Any more ideas?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Try this. See if this works:
=formatdate(Relativedate([Date2];-DaysBetween([Date2];[Date1]));"dd/MM/yyyy hh:mm:ss")
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
93 | |
10 | |
10 | |
9 | |
9 | |
7 | |
6 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.