Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
When we select multiple filters in QlikSense filters, they work like an OR condition. How to design a filter which will ONLY return records where the selected dimensions all exist together.
For example consider the below data:
Patient ID | Issue |
101 | Fever |
101 | Headache |
101 | Pain |
101 | Weight Gain |
101 | Nausea |
102 | Fever |
102 | Headache |
102 | Pain |
103 | Fever |
103 | Pain |
When I select Fever AND Headache I only want to see patient id 101 and 102.
By default if I select these two values, I will get all these ids, I ONLY want where the two dimension values exist together for an ID.
This set should do it:
{<[Patient ID]={"=count(DISTINCT Issue) = GetPossibleCount(Issue)"}>}
Exact syntax depends on the context. For example, to create a filterpane:
=aggr(
only({<[Patient ID]={"=count(DISTINCT Issue) = GetPossibleCount(Issue)"}>}
[Patient ID])
, [Patient ID])
For a chart expression that for example counts total visits:
count({<[Patient ID]={"=count(DISTINCT Issue) = GetPossibleCount(Issue)"}>} DISTINCT VistiId)
-Rob