Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Want to see what's currently in public preview? We've pulled it all together in one place. Check it out here
cancel
Showing results for 
Search instead for 
Did you mean: 
jyothish8807
Master II
Master II

Find time difference

Hi,

I have two fields : 1) date and time received : 12/16/2013 07:23 am

                          2) date and time sent :      12/17/2013 05:00 pm

No how can i find the total hours between date and time sent and date and time received.


Thanks & Regards

Jyothish KC

Best Regards,
KC
Labels (1)
11 Replies
jyothish8807
Master II
Master II
Author

Sure Jagan,

This a sample of my excel sheet.

NameDate ReceivedTime ReceivedDate sentTime Sent
a17-Dec-133:44 AM18-Dec-132:39 PM
b17-Dec-133:44 AM17-Dec-133:25 PM
c17-Dec-133:44 AM23-Dec-133:25 PM

Now i am trying to find out the time duration between both.

Best Regards,
KC
jagan
Partner - Champion III
Partner - Champion III

Hi,

Try this script

LOAD *,

IntervaL(Timestamp#([Date sent] & ' '& [Time Sent], 'D-MMM-YY HH:mm TT') - Timestamp#([Date Received] & ' '& [Time Received], 'D-MMM-YY HH:mm TT'), 'H') AS Diff

INLINE [

Name,Date Received, Time Received, Date sent, Time Sent

a, 17-Dec-13, 3:44 AM, 18-Dec-13, 2:39 PM

b, 17-Dec-13, 3:44 AM, 17-Dec-13, 3:25 PM

c, 17-Dec-13, 3:44 AM, 23-Dec-13, 3:25 PM];

Regards,

Jagan.