Skip to main content
Announcements
Join us at Qlik Connect for 3 magical days of learning, networking,and inspiration! REGISTER TODAY and save!
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Script

Hi,

can i use same age bucket for different dashborad...with different day limits..??if so means how??????

1 Solution

Accepted Solutions
PrashantSangle

Hi,

are you sure your data is like is this????

You can try like this

ZFIFO_Ageing:

LOAD * inline [

ZFStart,ZFEnd,ZFBucket

0,2,0-2 Days

3,5,3-5 Days

6,7,6-7 days

8,15,8-15 Days

16,30,16-30 Days

30,999999,>30 days

8,999999,>7 days

];

concatenate

//ZFIFO_Ageing1:

LOAD ZFStarts as ZFStart, ZFEnds as ZFEnd, ZFBuckets as ZFBucket inline [

ZFStarts,ZFEnds,ZFBuckets

0,2,0-2 Days

3,7,3-7 Days

8,15,8-15 Days

16,30,16-30 Days

30,999999,>30 days

8,999999,>7 days

];

IntervalMatch(ZF_Age)

Load ZFStart,

     ZFEnd

Resident ZFIFO_Ageing;

Regards

Great dreamer's dreams never fulfilled, they are always transcended.
Please appreciate our Qlik community members by giving Kudos for sharing their time for your query. If your query is answered, please mark the topic as resolved 🙂

View solution in original post

17 Replies
varshavig12
Specialist
Specialist

Can you give us an example for the same ?

Anonymous
Not applicable
Author

Hi sindhu,

you can create a same size of buckets by using class function.

and


you posted..can i create age buckets for different dashboards....means....plz elaborate with more details.

Anonymous
Not applicable
Author

For one dashboard, i have to create limits like 0-2 days,3-5days like tht,

For other dashboard,i have to create limits like 0-2 days,3-7 days like dt,

if i create means its shows the all limits in same dashboard,bt i need nly specific limits for specific dashboards.

Anonymous
Not applicable
Author

i mean to say,can i use the same age bucket for different dashboards

Anonymous
Not applicable
Author

Can you pls share the In-progress version of the script you have so that we can give our suggestions on that?

A sample should be a good way to 

Anonymous
Not applicable
Author

your using same data in both the dashboards?

Anonymous
Not applicable
Author

Ofcourse kalyani, but i have to use same data only...for diff dshboard....how can i do ths.

Anonymous
Not applicable
Author

Hi sindhu,

you can create a same size of buckets by using class function.

  Ex:

LOAD Name, DOB, Age

       Dual(Replace(Class(Age,5),'<= x <','to'), Num(Class(Aage,5))) as Bucket
FROM
[..\Desktop\Book1.xlsx]
(
ooxml, embedded labels, table is Sheet1);

  you can't create a same size of buckets by using if.

Ex:

 

LOAD Name, DOB Age,

  If(Date(DOB)>='01/01/1945' and Date(DOB)<='12/31/1960', 'Baby Boomers',
If(Date(DOB)>='01/01/1961' and Date(DOB)<='12/31/1980', 'Gen X',
If(Date(DOB)>='01/01/1981' and Date(DOB)<='12/31/1995', 'Gen Y','Gen Z'))) as Gen

    FROM
[..\Desktop\Book1.xlsx]
(
ooxml, embedded labels, table is Sheet1);

 

 

 

 

Anonymous
Not applicable
Author

what is your exact requirement sindhu...

you shared something limits on dashboards....can you please more detail,

then i will get clarity on your ..scenario.