Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
reivax31
Partner - Creator III
Partner - Creator III

Count(ID) only if date is max/min count(ID)

Hi Qlikers,

in the chart bellow we have "date" as dimenssion and count(ID) as measure.

In a simple KPI I would like to find the max and min value.  So this will be 13/04/2017  and 11/04/2017 in this case. What is the expression to get those values?

Thanks for your support

1 Solution

Accepted Solutions
vinieme12
Champion III
Champion III

For max

Max (Total   Aggr (YourExpression,Datefield) )

And for min

Min (Total   Aggr (YourExpression,Datefield) )

Vineeth Pujari
If a post helps to resolve your issue, please accept it as a Solution.

View solution in original post

4 Replies
vinieme12
Champion III
Champion III

For max

Max (Total   Aggr (YourExpression,Datefield) )

And for min

Min (Total   Aggr (YourExpression,Datefield) )

Vineeth Pujari
If a post helps to resolve your issue, please accept it as a Solution.
tresesco
MVP
MVP

Try expression like:

count({<DateField={'$(=Date(max(DateField)))' , '$(=Date(min(DateField)))'}>}ID)

reivax31
Partner - Creator III
Partner - Creator III
Author

It worked perfectly ! thanks !

reivax31
Partner - Creator III
Partner - Creator III
Author

Hi, this one gave me the value of my max(date) and min(date). So in this case value from 13/04/2017 and 10/04/2017.