Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
chadwatson
Contributor III
Contributor III

Two dimension Chart visualization

I am trying to create a bar chart with two dimensions and one measure. I would like both dimensions to show on my chart. I found in another discussion that to do this I needed to create a second measure and give it a value of 0. That worked, however every single value from the second dimension is being duplicated for every value in the first dimension:

The ones I've circled in red do not belong in those campuses. Here is the source data:

The measure is a calculation of how many weekdays there are between the effective date and end date:

=sum(NetWorkDays(iun_effective_date,iun_ending_date))

What I want to do is to get rid of those names that don't belong with the first level dimension. I've tried everything I can think of from checking "Suppress when Value Is Null" in the dimensions to "Supressing Zero-Values" in the Presentation. Does anyone have any other ideas? I'm not sure if it has to do with how I'm calculating the measure or something else.

Thanks!!!

9 Replies
caio_caminoski
Creator
Creator

Hi Chad,

Can you post a sample of your app?

Cheers

chadwatson
Contributor III
Contributor III
Author

It looks like someone just changed some test data I was working with so I'll see if I can recreate it.

chadwatson
Contributor III
Contributor III
Author

Here is the file. Thanks for your help!

My end goal is to sort first by campus numerically, then secondly by ins_full_name desc.

My second chart concats the two together which only shows the records I want, but then I have a hard time figuring out the sort, Plus I don't want to duplicate the campus number on every row; I'd prefer to have it there once.

martynlloyd
Partner - Creator III
Partner - Creator III

You could simplify it and create a concatenated dimension (in script) - then you get rid of the two dimension problem...

Kind regards,

Marty.

chadwatson
Contributor III
Contributor III
Author

Hi Marty,

In my example I attached I did that but then I have duplicated my first dimension for every row and it makes it harder to sort properly.

Digvijay_Singh

Hi,

Please check if this representation helps by writing small script and using dimension accordingly, attaching chart qvw as well.

temp1:
Load *, [IU Campus] & '-' & ins_full_name as [IU_INS]
Resident temp;

Thanks,

martynlloyd
Partner - Creator III
Partner - Creator III

Hi Chad,

Are you hiding null values in your chart - it should only show rows that have a non-null expression result...

Marty.

chadwatson
Contributor III
Contributor III
Author

Hi Marty,

Yes, I have checked those checkboxes but they have no effect.

Thanks,

Chad

chadwatson
Contributor III
Contributor III
Author

Thanks Digvijay,

Almost, I have done that as well but I have a couple problems with that way:

1. I prefer to not have it repeat the campus number for every row

2. more importantly I need to be able to sort it first by campus number, then by name's value decending with the the records with the highest numbers on top by campus number.

Chad