Skip to main content
Announcements
Live today at 11 AM ET. Get your questions about Qlik Connect answered, or just listen in. SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Date Range bucket >30 days,>15 days

Hi Guys:

i have created a straight table, in which i have listed the Tasks as follows

Taskid ProjectManager  CreateDate

1          JEJE                 01/01/2013

2          KEKE               12/13/2012

3         SMSM               12/28/2012

4          NNN                  11/13/2012

5          BBB                  12/10/2012

This table can grow very big. With this table,users also want a list box on filter criteria.Within this result set they can filter

only for Tasks where CeateDate <30 days. Also Tasks where Create Date is <15days

They want a list box somthing like    <30 days

                                                      < 15 days

how can achieve this.

I was checking other discussions on the similar topic on the forum. Looks like i should use interval match.

Interval match can be used to match dates into Month,Quarter etc.

Never used interval match before.

Is that the right approach for my problem and how do i do it.

Thanks.

1 Solution

Accepted Solutions
swuehl
MVP
MVP

I would suggest creating an additional field in the script, something like this:

LOAD

     Taskkid,

     ProjectManage,

     CreateDate,

    if( today() - CreateDate < 15, '<15 days',

          if( today() - CreateDate < 30, '< 30 days' )) as DateInterval

FROM ...;

View solution in original post

3 Replies
swuehl
MVP
MVP

I would suggest creating an additional field in the script, something like this:

LOAD

     Taskkid,

     ProjectManage,

     CreateDate,

    if( today() - CreateDate < 15, '<15 days',

          if( today() - CreateDate < 30, '< 30 days' )) as DateInterval

FROM ...;

Not applicable
Author

Thanks.

This worked.

Vijayqlik4171
Contributor III
Contributor III

I have  field 

Invoice date    //01/01/2004-01/01/2015 range 

I want 0-100days ,

100-300days,

300-500days 

500 more 

Screenshot_20210819-000619.png