There are four fields - Date In , Time In, Date Out, Time Out
Date fields are Type = Date , Time fields are Type = Time
I need to convert “Date In” and “Time in” to a DateTimeIn (Timestamp)
I need to convert “Date Out” and “Time Out” to a DateTimeOut (Timestamp)
Then,
I need to calculate the duration of (DateTimeOut - DateTimeIn) and result in number of minutes
Thanks.
First read this:
And then take a look at these:
Please see the expressions below and let me know what they should be, and also the expression for “Total Minutes”. I have reviewed the appsheet help but I am doing something wrong.
DateTime In
DateTime(Date([Date In])&" " &Time([Time In]))
DateTime Out
DateTime(Date([Date Out])&" " &Time([Time Out]))
DateTime In:
(DATETIME([Date In]) + ([Time In] - "00:00:00"))
DateTime Out:
(DATETIME([Date Out]) + ([Time Out] - "00:00:00"))
The the duration between them:
([DateTime Out] - [DateTime In])
Or skip DateTime In and DateTime Out altogether with:
(
(DATETIME([Date Out]) + ([Time Out] - "00:00:00"))
- (DATETIME([Date In]) + ([Time In] - "00:00:00"))
)
Better still, do away with Date In, Time In, Date Out, and Time Out and simply record DateTime In and DateTime Out directly.
See also:
That works. Thank you.
User | Count |
---|---|
41 | |
28 | |
28 | |
23 | |
13 |