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

Announcements
Discover how organizations are unlocking new revenue streams: Watch here
cancel
Showing results for 
Search instead for 
Did you mean: 
gizzel123
Creator
Creator

Creating user defined Age bucket in List box

Hi i have a column "Age".

I need to create an age bucket  which should have an interval of 5 yrs..

like-   (0-5),

(5-10),

(10-15)..... and so on.

Can u guys plz help..

thanks in advance


1 Solution

Accepted Solutions
Not applicable

sorry

try this

class(age,x,5)

View solution in original post

9 Replies
Not applicable

try this

class(age,15,x,5)

Not applicable

Use class function

Class(Age,5) as Age

Not applicable


Hi,

Like this u can create a Bucket.

If( age>0 and age<=5,'0-5',

       If( age>5 and age<=10,'5-10',

              If( age>10 and age<=15,'10-15',

                       If( age>15 and age<=20,'15-20','20 Above') as Age_Flag

Not applicable

sorry

try this

class(age,x,5)

gizzel123
Creator
Creator
Author

 

I  used Class(Age,5) but then m getting 0,5,10,15.......

For "0"selection -ages are0-4,

"5"selection -ages are5-10,.....so on

How would i Define the displaying string too

?

cz when i use class(age,15,x,5) it display -x as bad field name..

gizzel123
Creator
Creator
Author

I tried in chart...its working fine ..but not in list box.

Not applicable

can u tell me what u have written in chart  and we let u know why it is not working in listbox

gizzel123
Creator
Creator
Author

its working..i tried creating another list box...

Thanks All 

Not applicable

Hi

thanks for marking as correct answer ,

pls let me know which expression is suits for u