Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi Everyone,
I'm a beginner to Qlikview. Currently, I have a list box that shows ages 1-80 individually. I'd like to group them such that it's ages <10, 10-20, 20-30, and so on. This way, users can select on the age group as oppose to the specific age and will have data for all ages within that group displayed.
Thank you for you help!
Create a new field in the script that creates the groups:
LOAD
Age,
Class(Age, 10) as AgeGroup,
...other fields,
FROM
...
;
Then use that new AgeGroup field in the listbox
Try using Interval Match
GroupTable:
Load * Inline [
Start, Stop, Grouping
0, 9, 0 to <10
10, 19, 10 to <20
20, 29, 20 to <30
30, 39, 30 to <40
40, 49, 40 to <50
50, 59, 50 to <60
60, 69, 60 to <70
70, 79, 70 to <80
80, , 80 or more
];
IntervalMatchTable:
IntervalMatch(age)
load Start, Stop
Resident GroupTable;
Left Join (IntervalMatchTable)
Load Start, Stop, Grouping
Resident GroupTable;
Drop Table GroupTable;
left join(Facts)
Load age, Grouping
Resident IntervalMatchTable;
Drop Table IntervalMatchTable;
Then plot Grouping on a list box which will automatically associate with age in Facts.