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

Announcements
Join us to spark ideas for how to put the latest capabilities into action. Register here!
cancel
Showing results for 
Search instead for 
Did you mean: 
EliGohar
Partner - Specialist
Partner - Specialist

Set analysis - filter only records from the last 30 days

Hi

I'm trying to build a table which will filter only records from the last 30 days.

Here's a screenshot of what I'm trying to get (from left - the raw data, right - the desired table after filtering):

image.png

I tried this measure's expression:

max({<TIMESTAMP={">=$(Date(Today()-30,'DD/MM/YYYY'))"}>}Timestamp("TIMESTAMP",'DD/MM/YY hh:mm'))

but it seems to ignore the -30 part, it actually brings me all the records no matter what I'm defining after the "-" minus sign.

Any idea why?

2 Replies
David_Capan
Employee
Employee

When using set analysis, the date fields in your set expression need to have the same format.  Try this:

max({<TIMESTAMP={">=$(=Timestamp(Today()-30,'DD/MM/YY hh:mm'))"}>}Timestamp("TIMESTAMP",'DD/MM/YY hh:mm'))

 

EliGohar
Partner - Specialist
Partner - Specialist
Author

Thanks @David_Capan , however, when trying your expression on my environment I got no results in the table.

Also tried to return all the timestamp which is lower than today using this expression:

max({<TIMESTAMP={"<$(=Timestamp(Today(),'DD/MM/YYYY hh:mm'))"}>}Timestamp("TIMESTAMP",'DD/MM/YYYY hh:mm'))

image.png

Thanks,

Eli.