Qlik Community

New to QlikView

Discussion board where members can get started with QlikView.

Announcements
Make your voice heard! Participate in the 2020 Wisdom of Crowds® Survey. BEGIN SURVEY
Highlighted
Not applicable

Counting values

Hi I have a table as presented below

Location
USA
USA
USA
Spain
Italy
Italy

I need to count what is the maximum repetition of a country. For ex. in this case the result of expression should be 3  (USA occur 3 times, I don't need to know what country it is, just amount). This is just a sample table so in real case I can't use set analysis because of huge amount of different countries

Any idea how to solve that ?

Tags (1)
1 Solution

Accepted Solutions
Highlighted
anbu1984
Honored Contributor III

Re: Counting values

=Max(Aggr(Count(Country),Country))

View solution in original post

4 Replies
Highlighted
anbu1984
Honored Contributor III

Re: Counting values

=Max(Aggr(Count(Country),Country))

View solution in original post

Highlighted
jebamalai
Valued Contributor

Re: Counting values

Go to straight Table->Don't add any dimension->Create the expression->Count(Country)->Sort(Descending)->Go to Dimension Limits->Restrict the number of vaues you want to display

Highlighted

Re: Counting values

Hi.

do you mean like the attached?

Regards

ASHFAQ

Highlighted
MVP
MVP

Re: Counting values

Try below in Text Box

For Number

=MAX(Aggr(COUNT(Location),Location))

For Location

=FirstSortedValue(Location, -Aggr(COUNT(Location),Location))