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: 
zied_ahmed1
Specialist
Specialist

date -1

Hello,

I have a field named date with two dates (for example 18/03/2021 and 15/02/2021) 

I need to create a kpi with the value of every date 

i used in the set analysis :

Count(distinct{<date= {"$(=max(date))"}>}name)

to retreive the value of 18/03/2021

But when i use max-1 it gives me 0 because max-1 for him is 17/03/2021

 

any suggestions please ? 

 

Thanks 

 

 

1 Solution

Accepted Solutions
tresesco
MVP
MVP

Try using rank parameter in max(), like:

Count(distinct{<date= {"$(=max(date , 2))"}>}name)

View solution in original post

1 Reply
tresesco
MVP
MVP

Try using rank parameter in max(), like:

Count(distinct{<date= {"$(=max(date , 2))"}>}name)