Qlik Community

QlikView App Development

Discussion Board for collaboration related to QlikView App Development.

Announcements
QlikWorld, June 24-25, 2020. Free virtual event for DI and DA gurus. Register Today
cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Creator II
Creator II

Combine Dimensions in a Bar Chart

I have a bar chart that has  a Dimension of Brochures.Class. The data contains either Class III, Class II, Class I and OTC Drug.

Currently the chart lists each Dimension and sums the number of Total to Review and Total Completed in a stacked bar chart.

How can I combine the Class III and Class II bars into a single bar summing up both (Call it Class II/III). And do the same for Class I and OTC Drug (Call it Class I/Other). So I basically end up with a two-bar chart showing the sum of two expressions.

QVD is attached.

Thanks

Jeff

Tags (1)
1 Solution

Accepted Solutions
Highlighted
Partner
Partner

Re: Combine Dimensions in a Bar Chart

Hi Jeff,

Please add below code in dimension as calculated dimesion:

=If(Wildmatch(Brochures.Class,'Class 2','Class 3'),'Class II/III',

  If(Wildmatch(Brochures.Class,'Class 1','OTC Drug'),'Class I/Other'))


Thanks,

Arvind Patil

View solution in original post

7 Replies
Highlighted
Partner
Partner

Re: Combine Dimensions in a Bar Chart

Hi Jeff,

Please add below code in dimension as calculated dimesion:

=If(Wildmatch(Brochures.Class,'Class 2','Class 3'),'Class II/III',

  If(Wildmatch(Brochures.Class,'Class 1','OTC Drug'),'Class I/Other'))


Thanks,

Arvind Patil

View solution in original post

Highlighted
Partner
Partner

Re: Combine Dimensions in a Bar Chart

Please find the attachment.

Thanks,

Arvind Patil

Highlighted
Master III
Master III

Re: Combine Dimensions in a Bar Chart

Like this?

Highlighted
Creator II
Creator II

Re: Combine Dimensions in a Bar Chart

Arvind,that worked perfectly.

Thanks

Jeff

Highlighted
MVP
MVP

Re: Combine Dimensions in a Bar Chart

Please note that if you have to compare without wildcards, using match() is a better choice in terms of performance. And also, be careful of the fact that wildmatch() is case insensitive whereas match() is case sensitive.

Highlighted
Creator II
Creator II

Re: Combine Dimensions in a Bar Chart

Thanks, I'll keep that in mind

Highlighted
Partner
Partner

Re: Combine Dimensions in a Bar Chart

Happy to help you!

Thanks,

Arvind Patil