Bucket Creation In List Box

    Hi All,

     

    If anyone wants to show buckets in list box create them in script level, which is good for performance and also we can show frequency of buckets in list box itself. If your client asking you to create on the fly go for the other approach which i mentioned in attached qvw, this can be done with the help of class function.

     

    Expression for Bucket :

     

    Dual(Replace(Class(<field name>,<Bucket Interval>),'<= x <','to'), Num(Class(<field name>,<Bucket Interval>))) as Bucket;

     

    OR use simple if condition to create bucket

    Ex:     

    if( (age) = 0, '0',

        if( (age) >=1 and (age) <=10 , '1-10',

        if( (age) >=11 and (age) <=25, '11-25',

        if( (age) >=11 and (age) <=25, '11-25',

        if( (age) >=25 and (age) <=50, '26-50',

        if( (age) >=51 and (age) <=75, '51-75',

          age ))))))

     

     

    Cheers,

    Ganesh