Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi All
I am quite new to QlikView and with my colleague we are trying to have a list box for querying multiple fields, without success.
Perhaps you are more experienced, and you may help :
First we have a QlikView document and the data come from a Excel sheet
The Excel sheet has two headers because it is possible to have multiple object of the same nature, for example
Place | person1 | person2 | ||
---|---|---|---|---|
name | name | age | name | age |
beach | toto | 25 | tarzan | 32 |
street | jane | 32 | john | 50 |
office | mike | 42 |
We decided to simplify the file to a sigle header file:
Place-name | person1-name | person1-age | person2-name | person2-age |
beach | toto | 25 | tarzan | 32 |
street | jane | 32 | john | 50 |
beach | mike | 42 |
And then we created a QlikView document from this file
What we are trying to do now is to filter by age.
For exemple we want all place names that are frequented by at leat one person of 32 years old
for example : 32 will give : street and beach
Unfortunately when we create a list box, it is linked to one single field ? But what we want here is to query multiple fields with a logical OR.
Any suggestion about how we can achieve that? What is the right way to do?
Hope it is clear enough
Thanks in advance
If you can want to have two columns, you should be able to create this table with two header rows using a pivot table.
In the script add a PersonNum field to your Persons table to say whether will appear in column 1, 2 ... n.
On the pivot chart:
First dimension = PlaceName
Second dimension = PersonNum (the column identifier)
First expression = only(PersonName)
Second expresison = only(Age)
You could then drag and drop dimension 3 (PersonNum) onto horizontal header to show person-1 or person-2 etc. columns.
There are different ways to do this.
I would prefer to seperate the personnumber into a new field
In other word create data like this:
Place | Name | Age | PersonNumber |
beach | toto | 25 | Person1 |
street | jane | 32 | Person1 |
beach | tarzan | 32 | Person2 |
office | mike | 42 | Person1 |
street | john | 50 | Person2 |
office |
I attached an example of one way to do this.
Is this what you are looking for?
Good luck.
Dennis.