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

Announcements
Save $650 on Qlik Connect, Dec 1 - 7, our lowest price of the year. Register with code CYBERWEEK: Register
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Stacked bar chart – how to restrict the number of segments & maintain alphabetical sorting.

Hi all.

I have a stacked bar chart. I want to restrict each bar to just 5 segments, which should be the top 5 most common values. However the bar segments must appear in ascending sort order (alphabetically A-Z).

If I sort the chart by ValueDescription (A-Z) then the first 5 values are returned alphabetically, not the most common.

If I sort the chart by count(distinct EpisodeID) descending then the 5 most common values are returned, however they appear in the wrong order. Which renders my graph useless.

Any suggestions?

Is it possible to base the bar chart on a straight table? I could then apply the top 5 restriction to the table and maintain the sorting in the bar chart.

Thanks in advance, Michael.

0 Replies