Qlik Community

Ask a Question

New to QlikView

If you’re new to QlikView, start with this Discussion Board and get up-to-speed quickly.

Qlik Highlights 2020 Giveaway! Watch, reply and have a chance to win a $200 Amazon Gift Card! Watch Video
Showing results for 
Search instead for 
Did you mean: 
Creator II
Creator II

Need to find difference in minutes using two timestamp fields

Hi friends,

I just need to find the difference between two timestamp columns by minutes and also i have to remove seconds . Any suggestion would be really helpful.

eg: jan 12,2017 11:27:28 PM and jan 12,2017 11:37:22 PM

Actual answer using interval function including seconds: 9 minutes

Expected answer : 10 minutes (remove seconds and have to find difference)

23 Replies

Just use (TimeStamp2-TimeStamp1)*1440 the result will be in minutes then you can Round Up or Down depending on what you want.

Check attached using Peter's technique


Here is another approach

=Interval(TimeStamp#(TimeStamp(ORIG_RESTORE_TS, 'M/D/YYYY h:mm'), 'M/D/YYYY h:mm') - TimeStamp#(TimeStamp(NEW_RESTORE_TS, 'M/D/YYYY h:mm'), 'M/D/YYYY h:mm'), 'm')

View solution in original post

Creator II
Creator II

Sunny and peter,

kudos for your continuous effort. finally i achieve that using the above expression. Thank you. please stay in touch.