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: 
Quentinn
Contributor III
Contributor III

if difference between two timestamps is smaller than

Hi everyone, can't figure out how to write this.

I want to write a syntax to determine if the difference between two timestamps is smaller than 4 days

The best I came up with is this, but it won't work

 

count (if (INTERVAL(DATE(FirstValidatingDateTime - RegistrationDateTime),'ss') < 345600, 'sampleid'))

 

The idea is to count the sampleid's for which the difference between firstval and registration is less than 4 days (345600 seconds)

 

Can anyone help?

 

Cheers

1 Solution

Accepted Solutions
MarcoWedel

Count({$<sampleid={"=FirstValidatingDateTime-RegistrationDateTime < 4"}>} sampleid)

 

hope this helps

Marco

View solution in original post

1 Reply
MarcoWedel

Count({$<sampleid={"=FirstValidatingDateTime-RegistrationDateTime < 4"}>} sampleid)

 

hope this helps

Marco