Qlik Community

Ask a Question

New to QlikView

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

Announcements
Qlik Highlights 2020 Giveaway! Watch, reply and have a chance to win a $200 Amazon Gift Card! Watch Video
cancel
Showing results for 
Search instead for 
Did you mean: 
Contributor III
Contributor III

Can listbox values ignore selection in another listbox?

Hi everyone,

I have 2 listboxes. The first listbox, call it A, has 2 options  in it. The second listbox, B, has all the dates if 2014 in it.

When selecting one of the options in A, some dates in B disappear because the option that was picked never happened on those dates.

What I'd like to achieve  is that all dates will be displayed on B, regardless of the selection in A.
When a user will select a date that has no records of the option picked in A, count(optionA) will be 0.

Is there anyway to solve this problem?

Thank you.

1 Solution

Accepted Solutions
Contributor III
Contributor III

Found a rather hackish solution.

In my main dates table, I insert every date multiple times - each time coupled with one of the options form listbox A. This actually allows the user to see and select any date, regardless if the event picked in listbox A happened or not.

Very useful in my case, where I always have one selected field in a listbox which restricts the data to a subset and thus filters the date range, but I also want to see other non related data which happened during a broader time interval.

View solution in original post

8 Replies
MVP
MVP

May be you can try alternate state

You can move one of your two list boxes to the alternate state. Any selection in one of the list boxes won't impact the other. But I guess that is not your ultimate goal, what exactly are you trying to achieve?

Contributor III
Contributor III

I have a set of events I'm tracking. A subset of those events is presented by those options that appear in the first listbox (called "A").

I would like to see the count of ALL events at some time interval and also a count of the specific event I picked in listbox A.

The trouble is that when I pick an option that didn't happen on some date, that date is missing and I can't see the count of all the events.

Does that make sense?

I am sure there must be a reason for you to not do what I just do, but just so to make sure, have you thought about this: May be you can alter your expression which is doing the count. Add a statement like {<B = >} which would tell the expression to disregard any selections made in list box object for B field.

Best,

Sunny

Contributor III
Contributor III

Let's say you want to see the count of all events for specific day X, but that date isn't available in  listbox B because of the selection in listbox A. I can't see the data I want because that date is filtered out...

I'm aware it's a data modeling problem, but I'm trying to find a workaround for now.

I still feel that you might be able to do this in the expression itself: Count({<Date = >} Events). Would you be able to share a sample to look at?

Best,

Sunny

If you enable "show alternatives" for list box B, and possibly change the sort option to remove the State sort option, you should be able to see the values for B which are excluded by the selection in A.

Logic will get you from a to b. Imagination will take you everywhere. - A Einstein
Contributor III
Contributor III

Found a rather hackish solution.

In my main dates table, I insert every date multiple times - each time coupled with one of the options form listbox A. This actually allows the user to see and select any date, regardless if the event picked in listbox A happened or not.

Very useful in my case, where I always have one selected field in a listbox which restricts the data to a subset and thus filters the date range, but I also want to see other non related data which happened during a broader time interval.

View solution in original post