I'm trying to return the difference in hours and minutes between two DateTime fields.
I'm currently using the following
DateDiff ("n",{@DateTimeRecd},{@DateTimeRtd})
However, this only returns the number of mintues. Of course I can change it to DateDiff ("h",{@DateTimeRecd},{@DateTimeRtd}), but this is only hours.
I'm needing the time in hours and minutes.
Any ideas?
Thank you in advance for your assistance.
Request clarification before answering.
I figured this out by using the following formula. This will return number of days; hours and minutes.
CStr (int(Truncate (DATEDIFF('n',{@DateTimeRecd},{@DateTimeRtd}) /1440 ))) & "D " &
CStr (int(Remainder(Truncate (DATEDIFF('n',{@DateTimeRecd},{@DateTimeRtd}) /60 ),24))) & "H " &
CStr (int(Remainder(DATEDIFF('n',{@DateTimeRecd},{@DateTimeRtd}),60)))& "M "
I appreciate everyones assistance.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
| User | Count |
|---|---|
| 5 | |
| 5 | |
| 4 | |
| 3 | |
| 2 | |
| 2 | |
| 2 | |
| 2 | |
| 2 | |
| 2 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.