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

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
sspawar88
Creator II
Creator II

How to subtract 5 min from timestamp

i want to subtract a 5 min from today timestamp.

How can i get result for this in red()

if(Max(created_date)<> timestamp(today(),'DD-MM-YYYY hh:mm:ss') ,red())

1 Solution

Accepted Solutions
jonathandienst
Partner - Champion III
Partner - Champion III

This will subtract 5 minutes from the current time

TimeStamp(now() - 5 / (24*60))

(Today() contains the date only, now() contains the date and time - and there are 24 * 60 minutes per day)

Logic will get you from a to b. Imagination will take you everywhere. - A Einstein

View solution in original post

4 Replies
jonathandienst
Partner - Champion III
Partner - Champion III

This will subtract 5 minutes from the current time

TimeStamp(now() - 5 / (24*60))

(Today() contains the date only, now() contains the date and time - and there are 24 * 60 minutes per day)

Logic will get you from a to b. Imagination will take you everywhere. - A Einstein
sspawar88
Creator II
Creator II
Author

i want to check it for a data which is in my excel files.

how can i apply it for existing database

7/8/2015 11:57:31 PM--this is my last date

jonathandienst
Partner - Champion III
Partner - Champion III

I don't understand your question. Do you want to look for 5 minutes ago, or do you want to check when you last reloaded?

Logic will get you from a to b. Imagination will take you everywhere. - A Einstein
sspawar88
Creator II
Creator II
Author

In table object consist ID's, Min(created_date) and Max(created_date)

if i want to check whether this ID  is updated in last 5 min or not..if this is not updated i want to show in red().

is this expression correct ?

if(Max(created_date)<>  Max(created_date)-  5/(24*60) ,red())



Max(created_date) is 7/8/2015 11:57:31 PM