Qlik Community

New to Qlik Sense

If you’re new to Qlik Sense, start with this Discussion Board and get up-to-speed quickly.

Announcements
Customer & Partners, DEC. 9, 11 AM ET: Qlik Product & Strategy Roadmap Session: Data Analytics REGISTER NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
lailarhc
Creator
Creator

Wrong values displayed in bar chart

Hello.

This is probably a dumb problem, but I just can't seem to find the right expression to display the values I want on my bar chart.
Here's my expression for my bar chart: =Count(Aggr(Count(Curso), Servidor, Ano))

lailarhc_0-1624453668601.png 

It should show that 2 courses (curso) have been taken in 2021, but it's only showing 1. 

Here too, it's only showing 1 instead of 6.

lailarhc_1-1624454107228.png

Why is this happening?

Thank you in advance.

 

1 Solution

Accepted Solutions
sunny_talwar

Oh I see why that won't work... try this

=Sum(Aggr(Count(DISTINCT Curso), Servidor, Ano))

View solution in original post

5 Replies
sunny_talwar

Why don't you just use Count(Curso) here?

lailarhc
Creator
Creator
Author

It also gives me a wrong number: way higher than the actual count.

lailarhc_0-1624454689379.png

This should amount to 4, but it's showing 540.
I'm using Count(Curso) here

sunny_talwar

How about Count(DISTINCT Curso)??

sunny_talwar

Oh I see why that won't work... try this

=Sum(Aggr(Count(DISTINCT Curso), Servidor, Ano))

View solution in original post

lailarhc
Creator
Creator
Author

It worked!
Thank you 🙂