Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello,
I need to check if a timestamp difference is equal or greater than a number of hours and minutes.
ex.
I have two timestamp:
01/01/2015 12:40
01/01/2015 12:05
I have to check if the difference of those 2 dates is >= 4 hours and 30 minutes
in this example I expected to get 35 minutes as time difference that is < of 4 hours and 30 minutes
How can I achieve it ?
Many thanks in advance.
BR
Andrea
If these are loaded correctly as timestamps, you can just do this
TimeStamp1 - TimeStamp2 >= MakeTime(4, 30)
If not read correctly, then may be this:
TimeStamp#(TimeStamp1, 'MM/DD/YYYY hh:mm') - TimeStamp#(TimeStamp2, 'MM/DD/YYYY hh:mm') >= MakeTime(4, 30)
If these are loaded correctly as timestamps, you can just do this
TimeStamp1 - TimeStamp2 >= MakeTime(4, 30)
If not read correctly, then may be this:
TimeStamp#(TimeStamp1, 'MM/DD/YYYY hh:mm') - TimeStamp#(TimeStamp2, 'MM/DD/YYYY hh:mm') >= MakeTime(4, 30)
just the first one worked for me.
Many thanks.