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

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

OR selection in multiple fields

Hi guys,

I need to make a selection in various fileds: ex. the colour "yellow" in the "cars" selection table OR (not AND) in the bicycle one, and get the result at the same time.

Has anybody an idea for me?

Thanks.

N.

25 Replies
swuehl
MVP
MVP

And what do you expect instead, showing no families? Then add a calculation condition in your chart to check that both

fields have selections.

Anonymous
Not applicable
Author

When I select the yellow car I expect to get only the families with a yellow car,

When I select the yellow bike I expect to get only the families with a yellow bike

When I select both the yellow car and the yellow bike I expect to get the families with a yellow car OR a yellow bike

The behavior of a boolean OR...

rubenmarin

No selections in one field is more or less equal to select all values in that field, as swuelh said you must add a condition the check selections in both fields, something like:

If(GetSelectedCount(Car) and GetSelectedCount(Cycle), Count({<Cycle>+<Car>} Family), Count(Family))

Anonymous
Not applicable
Author

I've tried various casistics, but if I haven't the record yellow/yellow, it doesn't work well:


With these 3 records:

1, blue, yellow

2, yellow, blue

3, blue, blue

when I select the yellow car it's not possible to select the yellow bike and viceversa, so that I can't have the OR function 😞

swuehl
MVP
MVP

What about the attached solution, right side of the sheet. I used a data island for cycle to emulate the alternate state and added the logic for checking actual selections in fields.

Anonymous
Not applicable
Author

Great, swuehl!!

It's a quite complicated solution (I didn't understand it), but it work very fine!

Thank you so much!

N.