Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I'm trying to use the Interval function to get the difference in minutes between two timestamps, but the result is in error. Here's the function I'm using in my load script:
Interval(TimeStamp#(TimeStamp(EndLoadTimestamp, 'M/D/YYYY h:mm:ss'), 'M/D/YYYY h:mm:ss') - TimeStamp#(TimeStamp(BeginLoadTimestamp, 'M/D/YYYY h:mm:ss'), 'M/D/YYYY h:mm:ss'), 'm') as MinutesToLoad
Here's what the results look like:
Month(Date) | OrderType | SalesOrder | BeginLoadTimestamp | EndLoadTimestamp | MinutesToLoad |
May | SO | 21169443 | 5/30/2018 8:55:37 | 5/30/2018 8:58:12 | 0.00 |
May | SO | 21169414 | 5/30/2018 7:33:36 | 5/30/2018 7:33:37 | 0.00 |
May | SO | 21169344 | 5/30/2018 2:18:39 | 5/30/2018 2:19:26 | 0.00 |
May | SO | 21169342 | 5/29/2018 18:11:43 | 5/29/2018 18:11:56 | 0.00 |
May | SO | 21169191 | 5/29/2018 12:07:49 | 5/29/2018 12:08:14 | 0.00 |
May | SO | 21169175 | 5/29/2018 18:42:19 | 5/29/2018 18:42:19 | 0.00 |
May | SO | 21169139 | 5/29/2018 16:08:04 | 5/29/2018 16:58:59 | 0.04 |
May | SO | 21169123 | 5/29/2018 18:34:41 | 5/29/2018 21:38:01 | 0.13 |
Any ideas on how to get this work correctly?
Thanks.
Try this
Interval(TimeStamp#(EndLoadTimestamp, 'M/D/YYYY h:mm:ss') - TimeStamp#(BeginLoadTimestamp, 'M/D/YYYY h:mm:ss'), 'm') as MinutesToLoad
Try this
Interval(TimeStamp#(EndLoadTimestamp, 'M/D/YYYY h:mm:ss') - TimeStamp#(BeginLoadTimestamp, 'M/D/YYYY h:mm:ss'), 'm') as MinutesToLoad
Worked great. Thanks!
Do you know how this can be done as an IF Statement, I basically need to convert the times in Minutes to particular phrases. I've tried.....
=If(Interval(TimeStamp#([End Time]) - TimeStamp#([Start Time]), 'm') = '90','Basic')
So I want any appointments that are 90 mins long to show as Basic.
The (Interval(TimeStamp#([End Time]) - TimeStamp#([Start Time]), 'm') formula works correctly and shows the length of each appointment in Min's but the if statement is blank.
May be try this
=If(Interval(TimeStamp#([End Time]) - TimeStamp#([Start Time]), 'm') = MakeTime(1, 30), 'Basic')
That works great, thank you!
I cant seem to get this to work with any other time lengths?
I.e. I though 30 mins would be (0,30) or (30)
And 2 hours would be (2,00)
It is... 30 Minutes = MakeTime(0, 30) and 2 hours is MakeTime(2)
Both return blanks :/. Am I missing something here.
I have no idea... may be share a sample